An early, consistent finding is that when people converse or share an experience, their brain waves synchronize. Neurons in corresponding locations of the different brains fire at the same time, creating matching patterns, like dancers moving together. Auditory and visual areas respond to shape, sound and movement in similar ways, whereas higher-order brain areas seem to behave similarly during more challenging tasks such as making meaning out of something seen or heard. The experience of being on the same wavelength as another person is real, and it is visible in the activity of the brain.
Such work is beginning to reveal new levels of richness and complexity in sociability. In classrooms where students are engaged with the teacher, for example, their patterns of brain processing begin to align with that teacher's, and greater alignment may mean better learning. Neural waves in certain brain regions of people listening to a musical performance match those of the performer, the greater the synchrony, the greater the enjoyment. Couples exhibit higher degrees of brain synchrony than non-romantic pairs, as do close friends compared with more distant acquaintances.
More information:
https://www.scientificamerican.com/article/brain-waves-synchronize-when-people-interact/