The Sorting Hat actually spent a long time deliberating over Hermione.
She mentions it when somebody asks her about a particularly complicated piece of magic in Order of the Phoenix :
“How come you’re not in Ravenclaw?”
he [Terry Boot] demanded, staring at Hermione with something close to wonder.
“With brains like yours?”
“Well, the Sorting Hat did seriously consider putting me in Ravenclaw during my Sorting,” said Hermione brightly, “but it decided on Gryffindor in the end.”
This is a rare event, but not unheard of.
Pottermore has some more information on other borderline candidates: Hatstall.
An archaic Hogwarts term for any new student whose Sorting takes longer than five minutes.
This is an exceptionally long time for the Sorting Hat to deliberate, and occurs rarely, perhaps once every fifty years.
Of Harry Potter’s contemporaries, Hermione Granger and Neville Longbottom came closest to being Hatstalls.
The Sorting Hat spent nearly four minutes trying to decide whether it should place Hermione in Ravenclaw or Gryffindor.
As for why Hermione is sorted into Gryffindor over Ravenclaw, I think she answers this herself in Philosopher’s Stone .
On the Hogwarts Express, she shows a clear preference for Gryffindor over Ravenclaw: ”
I’ve been asking around
and I hope I’m in Gryffindor
, it sounds by far the best, I hear Dumbledore himself was one, but I suppose Ravenclaw wouldn’t be too bad…”
We know the Sorting Hat takes your choice into account, so if it was struggling to place her, then it might use her preference as the deciding factor.
Later, in the dungeons as they’re trying to get to the Philosopher’s Stone, we have this particularly telling line:
“I’m not as good as you,” said Harry, very embarrassed, as she let go of him.
“Me!”
said Hermione.
“Books!
And cleverness!
There are more important things – friendship and bravery
and – oh Harry – be careful!”
Hermione holds the values of Gryffindor – courage and bravery – higher than those of Ravenclaw – raw intelligence and knowledge .
She doesn’t just value these traits; she exhibits them throughout the books.
She encourages Harry to start Dumbledore’s Army; she fights with him in the Ministry of Magic; she works alongside him in the hunt for Horcruxes.
But she starts off as a stereotypical know-it-all, and we don’t really see much courage or bravery.
The Sorting Hat placed her in Gryffindor because she has the traits of a Gryffindor within her, and placing her in that house can bring them out.
She’s already very studious and intelligent, more so than a lot of Ravenclaws, so I think she has more to gain from Gryffindor than Ravenclaw.
scifi.stackexchange.com/users/3567/alexwlchan
Hermione is smart, intelligent, but also, she is the "take matters into your hands" type person, which is not a very Ravenclaw-y trait.
She wasn't very hesitant to create polyjuice potions despite knowing that they are highly illegal.
She also went ahead and trapped Rita Skeeter in a bottle!
She just goes for the right thing if it fits her conviction.
If you think about it, She is actually the perfect combination of Ravenclaw AND Gryffindor traits.
She is also strong and courageous when it comes to the tough decisions.
Erasing yourself from your own parents memories is something that would take more than all the courage in the world.
I feel we see a lot of her stronger aspects throughout the series.
She has all the identifying marks of Gryffindor on top of her intelligence, smartness.
This makes her a Gryffindor.
scifi.stackexchange.com/users/12551/Stark07
I read an interesting theory on Tumblr, titled The Golden Trio House : The Harry Potter trio are actually representations of the other houses.
Hermione is Ravenclaw, Ron is Hufflepuff, and Harry is Slytherin.
They’re all in Gryffindor because they asked.
In fact, everyone in that house could have been in another houses if they hadn’t asked to be in Gryffindor.
You have be ask to be in Gryffindor because their most defining feature is bravery, and anyone can choose to be brave.
scifi.stackexchange.com/users/29210/John Peyton
The author wanted to avoid a house hopping.
She wanted to have characters that interact.
It would have been more difficult to let them interact when Harry, Hermione and Ron would have been in different houses.
With the setup taken she could show them getting friends without too much interaction between Ravenclaw and Gryffindor.
scifi.stackexchange.com/users/25478/harper
If you will allow for Keirsian Temperament types , http://www.keirsey.com/sorthat.aspx , Gryffindor was Idealist and Ravenclaw was Rational.
Hermione is an INFJ.
Idealists often act like Rationals while they are growing up, especially until they learn to fit in.
Hermione, whose parents were not magical, worked very hard to fit in, acting much like a Rational to the untrained eye.
So, at first glance, she would fit into Ravenclaw, but on further analysis she was truly Gryffindor material.
scifi.stackexchange.com/users/26682/please delete me
She's clearly the smartest person in her year, and the defining trait of Ravenclaw is intelligence. Why would she be in Gryffindor rather than Ravenclaw?
Why was Hermione not in Ravenclaw?
scifi.stackexchange.com
<harry-potter><sorting-hat><hermione-granger>
scifi.stackexchange.com/questions/54865
scifi.stackexchange.com/users/22917/Often Right
Hermione holds the values of Gryffindor – courage and bravery – higher than those of Ravenclaw – raw intelligence and knowledge. She has all the identifying marks of Gryffindor  in addition to her intelligence and may benefit more from being in Gryffindor House. Hermione is not in Ravenclaw because she displays Gryffindor traits and lacks the creativity of thought of the Ravenclaws. Moreover, she is fearless and has strong convictions about right and wrong making her a Gryffindor and not a Ravenclaw.
Hermione is not in Ravenclaw because she displays Gryffindor traits and lacks the creativity of thought of the Ravenclaws. She is fearless and has strong convictions about right and wrong making her a Gryffindor and not a Ravenclaw.