Why did my limit order get executed at market price?

A market order gets executed immediately at the best available price in the market, while a limit order gets executed at or better than the limit price defined while placing the order.

For Example, for a Buy limit order, the order will get executed once the market price is equal to or lower than the limit price, while for a Sell limit order, the order will get executed once the market price is equal to or higher than the limit price.

If the Current Market Price is already lower than the Limit Buy Price, or higher than the Limit Sell Price, the order will get executed immediately at the Market Price.