There are two main uses of the semicolon (;): to join two complete sentences without benefit of a conjunction, and to separate items in a list when one (or more) of the items has a comma of its own.
In the first use, the trick is to imagine a see-saw. (Do we still have see-saws anymore? Maybe I should update my imagery, but this works so well!) So, each side of the see-saw is perfectly balanced, and in the middle is the semicolon: full sentence-semicolon-full sentence.
Example:
I ate the entire pint of Ben & Jerry’s New York Super Chunk Fudge ice cream. It made me sick.
I ate the entire pint of Ben & Jerry’s New York Super Chunk Fudge ice cream, and it made me sick.
I ate the entire pint of Ben & Jerry’s New York Super Chunk Fudge ice cream; it made me sick.
As an author, there are reasons that you’d choose one of these options over another.
In the first example, with the two full sentences, you can almost hear the pause and believe that the second sentence is (possibly) the punch line.
In the second example, with theĀ  comma and “and,” it seems like the “it” refers more to the eating than the ice cream.
In the third example, the one with the semicolon, it seems like the “it” refers more to the ice cream than the act of eating it. (You got sick because you ate this specific flavor of this specific ice cream.)
Bottom line: When you use a semicolon in this way, the material on either side of the semicolon has to be a full sentence. Not a full sentence? No semicolon!