In movies and TV series, I have seen Americans saying "Nice to meet you" when they meet someone. Its really weird, why would you say that in the beginning and not while ending the conversation? You barely know that person at the time.
If the phrase used started with it is or it was, then when it was said would make a difference. But since the exact phrase "nice to meet you" does not include a verbal tense, it can be said at either the start or the end of a conversation.
At the start of a conversation
✔ It is nice to meet you.
Whether the meeting is thought to be a 5-second greeting and handshake or an extended conversation, its still in the immediate present or just-completed past, so is is fine.
✘ It was nice to meet you.
Even if meet is considered to be that 5-second greeting and handshake which has just finished, the past tense would be odd at this point.
At the end of a conversation
- ✘ It is nice to meet you.
Nobody would normally say this at the end of a conversation. However, it's still less strange than saying it was as the start of a conversation.
- ✔ It was nice to meet you.
This is perfectly normal at the end of a conversation.
Without either it is or it was, "nice to meet you" can be said at either the start or the end of a conversation (assuming that the person being talked to has been met for the first time) and be meaningful at either time. In fact, it could be said at both times—for instance, once after shaking hands, and again when waving goodbye.
One answer could be that English (all languages I imagine) are full of stock phrases that do not necessarily make literal sense.
But it is presumably a statement that you anticipate it being a pleasant and mutually satisfactory encounter, so you are pleased that (it is nice that) it is taking place. It is to a agree a compliment to the other party.
If people didn't shorten the stock phrase it would be clearer that there is a difference between:
"It is nice to meet you" (present)
"It was nice to have met you" (past perfect)
It would sound more British English to say:
"It is lovely to make your acquaintance"
as "nice" is rather deprecated and "acquaintance" more specifically flags up that you didn't know them before (and is a little standoffish I suppose). On the other hand when parting it is probably appropriate to switch to
"It was lovely to have met you"
unles you really are trying to be standoffish. And English English is less formal that it used to be anyway.