When I have my back wheel gears in either the lowest gear or highest gear, my chain clicks as I pedal.
How do I fix this?
You may need to adjust your derailer limit stops (see here).
Listen to where the clicking is occurring. Look down while you pedal at the front derailleur and see if there is any rubbing. If so adjust accordingly. If there is no noticeable rubbing on the front then it is your rear derailleur that needs to be adjusted.
Be careful when doing this. I have messed it up a few times with leaves you with a bike that cant shift.
If you dont feel confident in doing this yourself a shop can do it for you rather quickly. Also a great time to get a tune up and sized if you havent been already.