The shah of Iran and his empress moved into a hotel on a quiet island in the Nile tonight after a welcome from Egypt with all the ceremony due the head of a friendly nation.

President Anwar Sadat met the shah personally at Aswan's little military airport and nothing about the official reception gave the slightest hint of the erosion of his power and the challenge to his rule that have transformed Iran since he last visited here a year ago.

But there was a widespread feeling here, as in Iran, that Mohammad Reza Pahlavi has embarked on his last journey as shahanshah , or kind of kings, and that the days of the dynasty founded by his father in 1925 are numbered.

No schedule for the visit by the shah and Empress Farah has been announced, nor is it known officially how long he will stay. The Egyptians have said that the schedule is up to him, although the hotel staff has been told he will remain there at least two days.

Sadat, who customarily spends several weeks in Aswan's warm sun at this time of year, has moved from his own residence into the Oberoi Hotel to be close to the shah and apparently has cleared his own calendar for the next two days to consult his troubled friend.

Former president Gerald Ford, who is due here Thursday on a private visit, also will be staying at the hotel and Egyptian sources say the shah is going to stay here at least long enough to meet with Ford.

The shah's blue and white Boeing 707 jetliner touched down at 3:55 p.m. It was follwoed a few minutes later by a cargo plane of the Imerial Iranian Air Force carring loaded packing crates, reinforcing the belief that the shah is planning an extended, if not permanent, stay outside Iran.

The monarch, whose once absolute power in Iran has been broken by a year of violent demonstrations, strikes and religious protests, appeared tense and drawn as he stepped from his plane onto the red carpet stretched acorss the tarmac.

A military band played a fanfare and cannon sounded a 21-gun salute as the shah, expressionless behind tinted glasses, greeted Sadat and Vice President Hosni Mobarak.

The shah and Sadat, old friends and political allies of nearly the same height, the same age and the same orientation, stood side by side at attention in their dark business suits as the band played the national anthems of Iran and Egypt. Then the shah reviewed a guard of honor, shook hands with Egyptian Cabinet ministers and other officials lined up beside the red carpet and joined Sadat and their wives for a brief chat over fruit juice in the airport VIP room.

The two leaders rode together in a closed Cadillac limousine on the 8-mile drive into town and then Sadat and the shah were seen in animated coversation on the open-topped excursion boat that took them to Elephantine Island. Crowds along the motorcade route were sparse and local officials put up only a few posters of the shah and Iranian flags along the way.

But there is no doubt that the shah will find the atmosphere here friendlier and more restful than it was at home, were mobs shouting "death to the shah" roamed the streets and demands for his departure kept the country in turmoil.

Aswan, a picturesque city of about 250,000 residents, is a favorite winter rsort for Egyptians. The shah and his wife have taken over 32 rooms of the Oberoi, which is reachable only by boat and where the loudest noise normally is the rustling of sails on boats carrying tourists across the river.

Sadat personally and Egyptians generally have watched the unfolding revolution in Iran with deep concern.Egypt had come to regard Iran as an anchor of stability for the entire Middle East and the collapse of the shah's power has left a regional vacuum that worries the Egyptians.

Officially, Egypt has welcomed the shah as the friendly head of a friendly nation to which Egypt is indebted for financial support in difficult times. But it is unclear whether Sadat actually invited the shah to come here or granted permission when the shah said he wished to visit. Acting Foreign Minister Boutros Ghali, who was at the airport, steadfastly refused to comment on the nature or pupose of the shash's visit.

Sadat, who speaks some Persian, has been on good terms with the shah since they met 10 years ago at an Islamic conference called to discuss a fire at the Al Aqsa Mosque in Israelioccupied Jerusalem. The two have maintained regular contact about regional problems and recently Iranian banks and industries have begun investing in Egypt.

The shah's religious opponenets led by the Ayatollah Ruhollah Khomeini, have said that he and other members of they royal family should be jailed and have denounced any leader who gives them refuge. But if Sadat so much as gave that a second thought, there was no sign of it.