Here's what screenwriters of the movie says about the ending.
Dinelaris said "a few different approaches" were considered, including
finishes that felt satirical or dramatic, before the writers settled
on what made the final script.
"We're not going to sit around and explain the ending. I guess my
thing is, if you can silence the voice of mediocrity, then what is
possible? [That] is good enough for me," Dinelaris said. "But we
thought if we answered that question at the end, it would seem very,
very small. Is he famous because he shot himself? That's small. Is he
still miserable? That's small. Everything seemed small."
Ultimately the writers decided to go with an ending that felt in
keeping with the film's central questions and lined up with the
elements of magical realism established by director Alejandro González
Iñárritu.
"It goes back to Alejandro because he starts the movie on ... this
character Riggan Thomson floating in his underwear three feet above
the ground. That's inexplicable. At that moment, it's inexplicable.
The last moment is inexplicable. They have to be, because in a way
that's Alejandro just trying to express that sense of confusion about
what he is in his own life," Dinelaris said.
And if you need more proof that there's no single answer about what it
means, look no further than Giacobone. "I'm still trying to figure it
out," he said.
EDIT:
After reading the last paragraph for couple more times, especially this line,
They have to be, because in a way that's Alejandro just trying to
express that sense of confusion about what he is in his own life.
I can come up with an explanation regarding the ending of the movie.
There were 3 times we were shown Riggan flying (or at least in the air.).
Beginning: He was not famous, family is not functional, daughter is in rehabilitation, one of the main character is being played by a mediocre actor in his play.
Intermediate: After having a rough and intense conversation with a critic, he fires himself up that he can regain his fame by making his play successful, on the other hand, his alter ego forces him to make a sequel of Birman movies, at this point, you can see a woman looking from a window while he was levitating and says,
WOMAN: Hey! Is this for real, or are you shooting a film?
But soon after when he reached theater, we figured out that none of this is real, it's all in his head, he's only imagining.
Ending: He's famous once again, he'll be doing this play in other countries as well, his family and fans cares for him, everything is in harmony. He is happy.
By combining the screenwriter's line and the intermediate flying scene, I can say that his daughter surprised, being happy and watching his father flying in the end is Riggan's state of mind. It did not happen for real just like the woman was looking at him in the intermediate scene while he was flying, it's his sense of confusion about what he is in his own life.