A lot of people have trouble distinguishing between with "your" and "you're" or "whose" and "who's." Many years ago I realized there's a simple rule for remembering which is which. I still get them wrong, but at least I can blame my fingers, since in theory I ought to be able to get it right.
Here's the rule: With personal and relative pronouns, apostrophes are used only in contractions and never in possessives. So the word it's, for example, stands for "it is" (as in "It's about time") or "it has" (as in "It's been too long"). You would no more write "everything in it's place" than you'd write "every king in hi's castle."
Of course, the rule assumes you know what "contractions," "personal pronouns," "relative pronouns, and "possessives" are, but all that's reasonably easy as well.
A contraction is just a shortened form of a phrase (or less often a single word), such as 'tis for "it is," I'll for "I will," or can't for "cannot." The apostrophe indicates were some letters have been left out.
The personal pronouns are what most people tend to think of as just plain pronouns: I, me, we, us, you, he, him, she, her, it, they, and them. The old-timey thou and thee fall into that category as well.
There are also a number of relative pronouns in English, but for our purposes the only one we need to talk about is who. (If you want to see a complete list check out this link.)
A possessive is a form of noun or pronoun showing (duh) possession, ownership, or a relationship conceptually similar. If you say "my pen" or "my notebook" you may very well mean that you bought it, but if you say "my friend" or "my country," or "my cat" you usually don't mean literal ownership.
Anyway, what the rule tells you is that it's, you're, they're, who's, and so on are all contractions and need those apostrophes, while "your," "their," "whose," etc. are possessives.
(Incidentally, while on the general subject of contractions, a lot of people understandably but mistakenly suppose that till is a shortened form of until and hence write it "'til." In fact, the older word is "till," and until is derived from till rather the other way around.)by