The hosts went ahead through David Luiz but were pegged back shortly afterwards by Alexis Sanchez and the game needed spot kicks to see Felipao's men into the next round
David Luiz officially opened the scoring for Brazil after Thiago Silva's flick-on from a Neymar corner, although replays seemed to suggest the ball had come off Chile's Gonzalo Jara.
But the host nation were pegged back just after the half-hour mark when Alexis Sanchez equalised following sloppy Selecao defending from a throw-in deep in their own half.
Brazil fans were then brought to their feet 10 minutes into the second half only to have their hopes of a second goal dashed after Hulk's strike was disallowed for a handball in the build-up.
Both South American sides struggled to fashion a better goalscoring chance as energy levels dropped and the game went into extra-time, when Mauricio Pinilla had the best chance to win the match for Chile by crashing a 20-yard strike against the crossbar in the 120th minute.
And so the last-16 tie had to be decided with spot kicks and it was Brazil goalkeeper Julio Cesar who stood out as the hero, pulling off two saves to see Luiz Felipe Scolari's men into the quarter-finals.
Three hours earlier, thoughts that a highly-charged atmosphere would simmer after the spine-tingling national anthems were quickly dispelled, as Fernandinho - starting in midfield in place of the much-maligned Paulinho - crunched into an early challenge.
Perhaps concluding that there was already enough yellow on show in the stadium, referee Howard Webb rightly kept his cards in his pocket.
Brazil started brightly, beating Chile at their own game as they pressed high and afforded their South American counterparts little space.
And after 18 minutes their endeavour brought the corner that created the opening goal, Thiago Silva flicking on Neymar's delivery to the back post - where Gonzalo Jara tussled with David Luiz. The Paris Saint-Germain-bound defender was officially credited with the goal, although replays suggested that Jara had got a decisive touch to divert the ball goalward.
Far from assuming control, though, Brazil were made to pay for some sloppiness at the back 14 minutes later, Eduardo Vargas intercepting a stray Hulk pass and sliding in Sanchez, who produced the coolest of side-footed finishes.
Suddenly end-to-end in nature, the game almost had a third goal before the break as Neymar, Fred and Dani Alves all went close.
Chile gave another reminder of their threat just prior to the interval, Alexis denied his second only by Luiz's last-ditch sliding challenge.
Another flashpoint came quickly after the restart, Brazil prevented from taking the lead when Hulk was crucially adjudged to have handled Marcelo's ball over the top, which had preceded a fine left-footed finish.
The decision was met by a cacophony of jeers from the home fans, but relief was to displace any feelings of injustice Brazil might have had a few moments later, Julio Cesar producing a stunning reactionary save to keep out Charles Aranguiz's effort following fine work from Arturo Vidal and Mauricio Isla.
Brazil continued to look dangerous at the other end, although Neymar's customary composure deserted him as he headed Alves' cross straight at goalkeeper Claudio Bravo - who was later on hand to keep out a powerful Hulk strike.
Extra time brought with it an added caginess - albeit with the exception of Hulk, who - apparently spurred on by a sense of injustice - was at the heart of everything, epitomised by a powerful effort that forced Bravo into a stop.
With Chile suddenly camped on their own box, further chances did not materialise but Jorge Sampaoli's underdogs almost snatched it right at the end of the added period - substitute Pinilla rattling the woodwork with a thunderous drive in the final minute as the hosts were afforded a huge slice of good fortune.
And it was one they took full advantage of. Brazil immediately took control of the shoot-out as David Luiz sent Bravo the wrong way and Pinilla saw his effort saved by Julio Cesar.
And, despite misses from Willian and Hulk, Jara rattled the post with the final kick to leave Neymar's cooly taken effort as the winning one.