Megachurch pastor Joel Osteen is shooting down claims his Lakewood Church in Houston turned Hurricane Harvey victims away, saying that keeping the doors closed for a few days during and after the storm was the "safe thing" to do.

"There was safety issues that people didn't see. They see this building sitting up on a high hill, looks like a high hill, but behind the building is where the water comes in. And so our flood gates were keeping the water out until, I'm told, Sunday night or maybe even early Monday," Osteen told Fox News in an interview at his Houston church.

Osteen was blasted on social media by critics who said he didn't do the "Christian thing" by immediately opening his church doors instead of waiting four days.

"The only thing me and Joel Osteen have in common is that I don't want people staying with me either," wrote one Twitter user.

"Remember @JoelOsteen was already invited by Jesus to help the suffering and homeless. He didn't need The city to invite him. Shame on him," another critic tweeted.

However, Osteen and a spokesman told Fox News that the Lakewood church is not a safe building to serve as a shelter because the first floor is underground and was taking on water until Monday and the main level is nearly all glass.

"We opened the building on Tuesday. I think that was the safe time to open it. I feel at peace about it," Osteen told Fox News.

Osteen said there were about six staffers who stayed in the building around the clock during the storm -- and in that time, three people showed up looking for shelter and were taken in.

"We asked our security staff, we asked everyone... we have not turned away anybody. So anybody was welcome and we did take people in," Osteen told Fox News.

The massive church, which holds services in an arena that was formerly home to the NBA's Houston Rockets, was thrust into the spotlight in part after TMZ posted a video of a man showing that the doors were closed and locked.

However Osteen's spokesman, Donald Iloff Jr., tells Fox News he thinks the video is a "hit piece" because the man in the video shows only a small section of the building's nearly 250 doors and didn't show himself in front of "entry" doors where staffers or security could have seen him.

"It could be somebody wanting to discredit us," Osteen said.

On Tuesday, Lakewood Church officially opened its doors to evacuees and ended up taking in hundreds of people.

"The city was taking people down to their shelter. They said, 'We're a shelter, you don't need to be a shelter.' When they filled up, they said, 'we're out of room' -- well of course we'll be a shelter," the pastor said.

Osteen says he has learned a lesson from the ordeal and is now going to bring in experts to asses the church building to decide what can be done to make it safer to potentially serve as a shelter in any future storms. "I think the notion that we weren't going to take people in or we don't care for people -- we've been doing that for 58 years and just somebody, somehow a false narrative caught on."