For many English teachers, ending a sentence with a preposition is something that won't be put up with. The reality, though, is that this idea is a fallacy, and in the vast majority of cases, where the sentence is structurally sound, ending on a preposition is nothing to be corrected for.
It is the Latin roots of English from which this idea has been spread about. In Latin grammar, a preposition was the one type of word that was wrong for a writer to end a sentence with. This idea has somewhat devolved in its translation into English, where the same rule has truthfully been more of a stylistic preference since.
If you’re really concerned about stylistic correctness, then generally speaking, the “rule” is more a guideline of rhetoric to be tread about.
The modern idea behind it is that it sounds much better to end a sentence in such a way that sounds firm and drives a point home, which is generally not something prepositions are good for. Though it’s still a fallacy we hear today, examples debunking it can be found at the source, and date as far back as 110 years before. Image: