In the previous chapter (12:46-50) we saw how Jesus' family stood outside the house where he was teaching and asked to have a word with him, presumably to get him to stop this Messiah nonsense and come home. So we knew that Jesus must have been teaching within the vicinity of his home town, and now see him arriving at Nazareth and teaching at the synagogue he probably grew up in as a boy.
There is a saying that "familiarity breeds contempt." Well, that is exactly what's happening here. The people of Nazareth are astonished at Jesus' teaching, but not in a good way. They are not "astonished/awed" but rather are "astonished/indignant." Who on earth does this guy think he is? Sure, he might be able to "ooh!" and "aah!" everyone else, but we knew him when he was just a snot-nosed kid in diapers. The carpenter's son, right? Wife's name is Mary and their other sons are James, Joseph, Simon and Judas. Why, my next-door neighbor is married to one of his sisters! So hometown boy leaves to go out into the world, and all of a sudden he just shows up with his entourage and starts teaching in our synagogue as if he's better than us? The nerve!
There is nothing that blinds you from the truth more quickly than thinking you already know the truth. The Nazarenes assume they already know who Jesus is, which is why they completely miss the boat. The irony is that they are going to miss the boat even further because Jesus won't perform any miracles in the face of such unbelief. I can just hear them saying, "So where's all this hocus-pocus we've heard so much about? He hasn't done a thing since he's been with us. Just goes to show they were all tall tales to begin with." It becomes a downward spiral: Unbelief ---> God withholds his miracles ---> more unbelief ---> God continues to withhold his miracles ---> further unbelief, etc.
Conversely, having faith is what opens your eyes to see who Jesus is, which gives you further reason to continue believing, which then enables you to see him even more clearly. Faith and spiritual sight together form an upward spiral. We know that later on Jesus' mother and at least some of his brothers would get turned around and finally grasp Jesus' true identity. James and Judas would become leaders in the church, and both would write epistles (James and Jude) in which they refer to themselves as "bond-servants of Jesus Christ." Not blood brothers who grew up with Jesus, who try to position themselves for a book deal where they reveal the inside scoop on who the Messiah really is. James and Jude would eschew special treatment and instead take their place in the church as merely disciples of their Savior. It is really a remarkable transformation when you consider how far they came from the cynicism and unbelief of the Nazarenes in this passage. It gives you hope that with God anything is possible.