\text{\textdollar}
The command \text{\textdollar} is used in LaTeX to produce the dollar sign ($) within text mode. This is particularly useful when you want to include a dollar sign in a document without switching to math mode, ensuring that the symbol is treated as regular text rather than a mathematical operator.
Displaying a price in text mode with a dollar sign.
The price is \text{\textdollar}20.
Showing earnings with a dollar sign in a sentence.
He earned \text{\textdollar}1000 last month.
Indicating the cost of an item using a dollar sign in text.
The book costs \text{\textdollar}15.99.