A trailing stop is a stop-loss that follows the price when a trade moves in your favour, staying a fixed distance behind it. If the price turns, the stop stays where it is, and closes the trade if it is reached.
Example: you buy EUR/USD at 1.1000 with a 30-pip trailing stop. If the price rises to 1.1080, the stop rises to 1.1050. If the price then falls back, the stop holds at 1.1050 and the trade closes there with a 50-pip gain.
Strengths and limits
Trailing stops protect profits in trending moves without capping how far a trade can run. Their weakness is choppy markets: a trail that is too tight gets hit by normal noise, while one that is too loose gives back a lot before it closes.
Many traders set the trailing distance from volatility, for example a multiple of the ATR. On MetaTrader the built-in trailing stop runs on your computer, so it only works while the platform is open; server-side trailing depends on the broker.