Both words come from the Latin stationarius, which referred to a trader who was based in a fixed location rather than travelling from place to place to sell their goods.

According to the ancient Stationers’ Company, one of the many livery companies created by medieval tradesmen within the City of London, when manuscript writers and illuminators decided to set up stalls or stations around St Paul’s Cathedral they were given the nickname stationers.

Stationary is an adjective or adverb meaning ‘not moving’ or ‘not changing’ or ‘having a fixed position’.
Example: While the market is improving, sales have been stationary for the last month.

Stationery is a noun or adjective and relates to all the materials needed for writing such as paper, pens, pencils, notebooks, envelopes, ink, etc.
Example: We supply all your office needs, including stationery, printers and furniture.

The most common mistake people make is to write stationary when they mean stationery (and not the other way round).

I always think of the ‘er’ in paper to remember the spelling is stationery when referring to writing materials.