cant join my own server but a friend can

I cant join my own server I am hosting, but my friend can.

Ive followed all the steps to hosting a server, and my friend can join the server. However, when I try to join my own server, it just locks me in a connecting to server message and never connect.


(replace this with a guide to solving this issue. use an enumeration like 1., 2., for solutions with multiple steps, and use headings (### Solution Title) for multiple solutions)