It depends on where you are and how you use it. 小姐 (xiǎojiě) literally means "Miss" and was once the standard polite way to address a young woman, the way "miss" works in English. In Taiwan, Hong Kong, and Cantonese-speaking regions, it's still completely neutral and polite — you'd use it for a waitress, a shop assistant, or any woman whose name you don't know.
In mainland China, though, especially in the north and in everyday urban speech, 小姐 has picked up a strong association with sex workers, because it became a common euphemism for prostitutes starting in the 1990s. Calling a stranger 小姐 to her face in Beijing or Shanghai today can be genuinely insulting or at least very awkward, even though the dictionary meaning hasn't changed.
What mainlanders use instead: 女士 (nǚshì, "madam/ma'am," more formal), 美女 (měinǚ, literally "beautiful woman," now used casually like "miss" for any young woman, especially by service staff), or just 你好 (nǐ hǎo) to get someone's attention without a title at all.
So the short version: fine in Taiwan/Hong Kong, risky in mainland China unless you're specifically saying "the young lady over there" in a clearly formal or written context — and even then many people will avoid it now.