Shōjo (少女) is a Japanese word meaning "girl". The characters, or kanji, mean "little" and "woman". The word is mainly used to describe a demographic for anime and manga- girls 7-19.
Like many Japanese words, the characters of the word shōjo come from Chinese. The first known use of the word comes from a Chinese book called The Book of the Later Han. In Chapter 86, young girls are mentioned:
盤瓠種，昔帝嚳時患犬戎入寇, 乃訪募天下，有能得犬戎之將吳將軍頭者，購黃金千鎰，邑萬家，又妻以少女 Translation: The myth of Yao: the country is being invaded by barbarians, the king is looking for warriors who are able to take the head of the general of the invading army, and for this the king will award a thousand Yi of gold, many houses, and young girl(s) as their wife/wives.
The word was brought to Japan in the 7th century, when they began using a Chinese-style legal system. During this time, shōjo meant girls from 17 to 20.
Modern Use change
Nowadays, the word shōjo is legally used to mean any woman or girl under 20. This is like how shounen is used to mean men or boys under 20.
Outside of legal use, the word shōjo is used to refer to things for girls or about girls, like shōjo manga, shōjo anime, and shōjo fashion.