Whether you are making your own tent, or need to replace an old zipper on a tent, sewing a tent zipper is fairly simple. You can use both coil and tooth zippers, as long as it is not a continuous zipper. For tents, coils of size #5 are the most commonly used. It is the same type of zipper used for jackets and other outdoor equipment. (see Reference 1)
Set-up your sewing machine. Install your zipper foot and pass the thread through your machine. Sew on a test patch to make sure it is set-up properly.
Remove the old zipper if you are installing a new one on an old tent. Make sure all the parts are removed and that you clean the fabric of thread remnants. If the edge is not straight, use a pair of scissors to make it even, but be sure not to remove too much fabric. Less than a 1/4 inch if possible.
Separate the zipper and lay one side, right-side down, along the edge of the fabric from the exterior of the tent door. Use pins to secure the zipper to the door flap. Do the same with the second half of the zipper, and secure it to the other tent door flap. Make sure that the bottom and top stops are aligned.
Sewing as straight as possible, stitch the zipper tape side up. Do a backstitch at the start and at the end to secure the zipper in place properly. Repeat on the other side of the tent door.
Topstitch each side of the zipper. Start with the right side of the fabric and turn the zipper tape under it. Make a crisp fold along the previous stitches. Start and finish with a backstitch or a bar tack. Sew in a straight line with the right edge of your presser foot against the zipper teeth as a guide.