Why do people bow at temples or shrines?

I visited a local shrine with my European friend recently, and she noticed that I bowed once before passing through the red torii gates and asked me why. It’s so second nature to me that I actually found it a little challenging to verbalize the reasoning to her, but eventually, I managed to explain that it’s a sign of respect and recognition that we will enter the domain of the gods once we pass through the gates. I also told her that the middle of the path is meant for the gods, so it’s proper etiquette to walk along the sides toward the main hall.

File ID 168405693 | © Christopher Bellette | Dreamstime.com

I was worried she would feel overwhelmed or intimidated by all of the rules but her eyes were lit up with sparkly curiosity, which made it so fun for me too, as I learned how to explain the numerous “why” of my culture for the first time.