Virtues of Makkah and Madinah
Question

Is living in the city of the Messenger of Allah better, or living in Makkah Al-Mukarramah? What are the differences that make one of the two cities better than the other, apart from the difference of virtue of praying in the two Harams?
Praise be to Allah.Which city is the best for living as a Muslim?
The best spot on earth, in and of itself, is Makkah, then Madinah.
With regard to individuals, what is best for each person is to live in the city where his faith will increase and he will be able to worship and obey Allah, may He be Exalted, more.
Shaykh Al-Islam Ibn Taymiyah (may Allah have mercy on him) said:
“The best place on earth for each individual is the land where he will be more able to obey Allah and His Messenger, which varies according to circumstances. There is no specific land in which it is best for a person to reside. Rather what is best for each individual is to be determined based on the degree to which he will be able to attain piety, obedience, humility before Allah, submission and focus on worship. Abu Ad-Darda’ (may Allah be pleased with him) wrote to Salman (may Allah be pleased with him), saying: Come to the holy land. Salman wrote to him: The land does not sanctify anyone; rather what sanctifies a person is his deeds.” (Majmoo‘ Al-Fatawa, 18/283)
Virtues of Makkah 
Makkah is distinct from Madinah and other cities because of a number of virtues, of which we will mention the following:

One prayer in Al-Masjid Al-Haram in Makkah is better than one hundred thousand prayers offered in any other mosque, except Al-Masjid An-Nabawi [the Prophet’s mosque], in which one prayer is better than a thousand prayers offered elsewhere.
Makkah is unique in that it is the place where Hajj and ‘Umrah are performed, people circumambulate the Ka‘bah, touch the Black Stone and the Yemeni Corner (Ar-Rukn Al-Yamani), and do Sa‘i between As-Safa and Al-Marwah.
Allah, may He be Exalted, swears by it, as He says (interpretation of the meaning): “I swear by this city (Makkah)” [Al-Balad 90:1].
Allah, may He be Exalted, decreed Makkah to be a sanctuary the day He created the heavens and the earth, which is not the case with Madinah.
The sanctity of Makkah is greater than that of Madinah. 

Shaykh Ibn ‘Uthaymin (may Allah have mercy on him) said:
“Madinah is a sanctuary and enjoys sanctity, but its sanctity is much less than that of Makkah. No Muslim can come to the sanctuary of Makkah from outside the Haram boundary, unless he is in the state of Ihram, and he must enter Ihram. That is not so in the case of Madinah.
In the sanctuary of Makkah, the grass and trees (i.e., all plants) are protected, whereas in the sanctuary of Madinah, a concession is granted regarding some of its trees for the purpose of agriculture and the like.
Hunting game in Makkah is prohibited, and a penalty must be paid for that, whereas no penalty is required for hunting game in Madinah.
The point is that the safest place is Makkah, where even the trees are safe, and even game animals are safe.” (Liqa’ Al-Bab Al-Maftooh, 103/2)
Virtues of Madinah

Madinah is the location of Hijrah (migration), the place where the Muhajirin and Ansar came together. And it is the centre of Jihad, from which the armies marched forth and campaigns were launched, from which lands were conquered, the religion spread and Shirk and its people were defeated.
In Madinah, most of the verses on rulings and laws were revealed. When the Prophet (blessings and peace of Allah be upon him) conquered Makkah, he did not settle there; rather he returned to Madinah, the city to which he had migrated, and lived there until he died and was buried in that city.

Al-Bukhari (3778) and Muslim (1059) narrated that Anas (may Allah be pleased with him) said: The Ansar said on the day of the conquest of Makkah, when (the Prophet (blessings and peace of Allah be upon him) gave (some of the booty) to Quraysh: By Allah, this is strange. Our swords are still dripping with the blood of Quraysh, and our spoils have been given to them! News of that reached the Prophet (blessings and peace of Allah be upon him), so he summoned the Ansar and said: “What is this that I have heard about you?” They were people who never told lies, so they said: It is what you have heard. He (blessings and peace of Allah be upon him) said: “Does it not please you that the people are going back to their houses with worldly gains whilst you are going back to your houses with the Messenger of Allah? If the Ansar were to follow a valley or mountain pass, I would follow the valley or mountain pass of the Ansar.”
Al-Bukhari (1871) and Muslim (1382) narrated that Abu Hurayrah (may Allah be pleased with him) said: The Messenger of Allah (blessings and peace of Allah be upon him) said: “I have been enjoined (to go to) a city which supersedes other cities. They say Yathrib, but it is Madinah. It purifies people as the bellows eliminates the impurities of iron.”
An-Nawawi (may Allah have mercy on him) said:
“With regard to it superseding all other cities, they mentioned two meanings, the first of which is that it was the centre for the armies of Islam in the beginning, and from it other cities were conquered and their wealth and captives seized. The second meaning is that it superseded and its food and provision came to it from the conquered cities, from which booty was brought to it.” (Sharh An-Nawawi ‘Ala Muslim, 9/154)
Al-Bukhari (1876) and Muslim (147) narrated from Abu Hurayrah (may Allah be pleased with him) that the Messenger of Allah (blessings and peace of Allah be upon him) said: “Faith will retreat to Madinah as a snake retreats to its hole.” (Mirqat Al-Mafateeh, 1/243)
Madinah is the gathering-point of the Muslims in the beginning and at the end. An-Nawawi (may Allah have mercy on him) said:
“Faith will retreat to Madinah” – what is meant is that this is how faith is in the beginning and at the end, because at the beginning of Islam, everyone whose faith was sincere and whose Islam was valid came to Madinah, either as a Muhajir (migrant) coming to settle there, or out of a longing to see the Messenger of Allah (blessings and peace of Allah be upon him), and to learn from him and be near to him; then after that, at the time of the caliphs, people did the same, so they came to learn about the straight path from them and follow the example of the majority of the Companions (may Allah be pleased with them) living there; then after that, they came to learn from the scholars of Madinah who were a shining lamp of that era, and the Imams of guidance, to learn Islam and the Sunnah of the Messenger of Allah (blessings and peace of Allah be upon him) that the Companions narrated to subsequent generations…. Therefore everyone who was steadfast in faith and at ease with it would travel there. “ (Sharh An-Nawawi ‘Ala Muslim, 2/177)

In Madinah there is the Prophet’s Mosque and the blessed Rawdah. Al-Bukhari (1196) and Muslim (1391) narrated from Abu Hurayrah (may Allah be pleased with him) that the Prophet (blessings and peace of Allah be upon him) said: “The area between my house and my minbar is one of the gardens of Paradise, and my minbar is upon my cistern (Hawd).”

In it is the valley of Al-‘Aqiq, which is a blessed valley. Al-Bukhari (1534) narrated from Ibn ‘Abbas (may Allah be pleased with him) that he heard ‘Umar (may Allah be pleased with him) say: I heard the Prophet (blessings and peace of Allah be upon him) saying in the valley of Al-‘Aqiq: “Last night someone came to me from my Lord and said: ‘Pray in this blessed valley, and say: (I intend to do) ‘Umrah and Hajj.’”

No one intends ill towards the people of Madinah but Allah will destroy him.

Al-Bukhari (1877) and Muslim (1363) narrated that Sa‘d (may Allah be pleased with him) said: I heard the Prophet (blessings and peace of Allah be upon him) say: “No one plots against the people of Madinah but Allah will cause him to dissolve as salt dissolves in water.”
Whomever Allah blesses by causing him to live in Makkah, congratulations to him; and whomever Allah blesses by causing him to live in Madinah, congratulations to him; and whomever Allah blesses with piety – no matter where on Allah’s earth he lives – congratulations to him.
For more details, please see the following answers: 146927 , 228704 , 20965 , and 47736 .
And Allah knows best.