I’ve seen a lot of suggestions, some from folks who should know better, but obviously don’t.
Venting through a roof should only be an option on new construction, and then only if you plan on staying in the house forever.
Roof systems protect your house from the weather. They are composed of shingles, underlayment, sometimes rubber sheeting and gravel, etc. Cutting a hole in a roof is not something that the homeowner should ever consider doing him/herself. Always call a roofing expert to do the work for you — they will install the proper ducting materials for you and ensure that the work is finished so that your roof is once more leak free.
While it may to be a no-brainer that heat rises and one should take advantage of that fact, the actuality is that there is far more involved in going up than there is in going out (a side wall). Let’s assume a single story house…first, you have to locate and cut through the sheet rock on the ceiling of the room — this means penetrating a vapor barrier which keeps any moisture in the attic space –> in the attic space where it belongs. Then, you have to move aside insulation, which keeps the rooms below warm, then cut a hole in the roof. You will have to carefully remove shingles, install the proper vent duct, seal the vent duct to the roof, replace the shingles, usually with some soft of asphaltic sealant, mount the duct to the roof vent, reseal the vapor barrier, replace the insulation, then mount the ducting to the rest of your exhaust system. This is a lot of work!!
In many cases, it is far simpler and less costly to either duct out through a window opening or cut a hole in an outside wall than it is to go through the roof.