In the Classic TWS or Mosaic, simply right click on the position line within your Portfolio page or Watchlist page and click on the small “Close” button. In IBKR Mobile, tap on the “Close” button. This creates an order row or order ticket that identifies the order as "Closing". Be sure to carefully check the order details before submitting the order.
If you need help closing an open position, please contact the IBKR Trade Desk.