Tether is obviously the most stable one, but as others have noticed, it's centralized and thought it would be easiest solution, it's not a great answer to your question.
A better way would be to have 2 different coins. Let's call them "FixCoin" and "FixCoin Dollar", or FC & FCD.
Now we would want FixCoin Dollar to be fixed at $1. How could we achieve this?
First, we would have to get miners or similar creatures to check the price of FixCoin continuously.
Next, we would add the possibility of turning FixCoin Dollars into FixCoins and FixCoins into FixCoin Dollars on the blockchain, which should be possible to achieve if the price is checked on a decentralized way, i.e. miners. FixCoin is checked at the market rate and FixCoin Dollar at the fixed price of $1.
Now, when FCD goes below $1, people would start turning FCD into FC, thus driving the price of FCD up.
Then, when FCD goes above $1, people would start turning FC into FCD, thus driving the price of FCD down.
Not a flawless system, of course. Low volume, large market influencers (LFI/Whales) could sabotage this system. Sadly, it's quite hard to keep a completely decentralized coin at a fixed price. Even keeping it "stable" isn't that easy.