A limit order sets the worst price you will accept: buy at or below your limit, or sell at or above it. It gives you price control but no guarantee of being filled.
Limit orders are useful for entering at a better price than the current market, or for taking profit at a target. If the market never reaches your price, the order simply does not execute.