The verb is sent to the end of the sentence after certain conjunctions called subordinating conjunctions. You simply have to learn what these conjunctions are, as there is no specific rule.
Subordinating conjunctions are the following:
weil (because)
dass (that)
obwohl (although)
wenn (when [in present/future]/if)
ob (whether)
warum (why)
während (while/during)
bevor (before)
seitdem (since)
nachdem (after)
so lange (as long as)