How do they know? Because your Visa into the country states your religion. If you want to get into Mecca itself, you'll probably need a Hajj Visa. read more
Meccans dont know if you are a Muslim or not. As muslims have no physical differences of that of non muslims. if you can make through the security check at the border of Makkh no one is going to ask you what is your religion. Everyone assumes you are a Muslims. read more
The prophet Muhammad designated Mecca as the holy city of Islam and the direction (qibla) in which all Muslims should offer their prayers. In addition to prayer, a pilgrimage to Mecca is required of every Muslim who can afford it as one of the Five Pillars of the faith. read more
dear mecca is also place where Muslims are praying that place is not for tour in pilgrim days only short list people (Muslim) allowed due to huge crowed I do not know why non Muslim want to go there every one knowing that place for praying nor enjoyment ( tour ). read more
No they don’t know for sure. But they would check your papers and determine if you're a muslim of not. Since most foreigners in mecca and medina were most likely there to do hajj they will scrutinize anyone that doesn't go there to do hajj and asking for further confimation and references. read more