Visa, what is it, why is it invented and where did come from?

A visa (from the Latin charta visa, meaning “paper which has been seen”) is a conditional authorization granted by a country (typically to a foreigner) to enter and temporarily remain within, or to leave that country. Visas typically include limits on the duration of the foreigner’s stay, territory within the country they may enter, the dates they may enter, or the number of permitted visits. Visas are associated with the request for permission to enter a country and thus are, in some countries, distinct from actual formal permission for an alien to enter and remain in the country. In each instance, a visa is subject to entry permission by an immigration official at the time of actual entry and can be revoked at any time.

Wikipedia continues with:

A visa is most commonly a sticker endorsed in the applicant’s passport or other travel document. The visa, when required, was historically granted by an immigration official on a visitor’s arrival at the frontiers of a country, but increasingly today a traveller wishing to enter another country must apply in advance for a visa, sometimes in person at a consular office, by mail or over the internet. The actual visa may still be a sticker or a stamp in the passport or may take the form of a separate document or an electronic record of the authorization, which the applicant can print before leaving home and produce on entry to the host country. Some countries do not require visas for short visits.