In a perfect world, we'd only use Airbnb to book geodesic dome lofts and 14th century Transylvanian castles.

But the world isn't always perfect. And when the going gets rough, Airbnb serves a much different secondary function: a place to secure — and to offer — free, short-term accommodations.

Inspired by New York- and New Jersey-based hosts who opened up their hearts and their homes to displaced neighbors in the wake of Superstorm Sandy, the company's emergency housing relief program, Open Homes, first launched in 2013 under a slightly different form as the Airbnb Disaster Response Tool.

The idea behind the original Disaster Response Tool was simple. In the immediate aftermath of natural disasters and other events, a series of special features were activated: Airbnb host communities in specific cities/regions were notified and asked if they'd be willing take in impacted guests, booking fees were waived and local residents who weren't already registered hosts but wanted to provide lodging to the displaced were looped in. A dynamic landing page was also launched to make it "easy for guests to browse listings and request to stay with a host during their time of need."

As with normal bookings, all reservations made through the Disaster Response Tool were covered by Airbnb's Host Guarantee.

The Airbnb Disaster Response Tool was used several times in that first year. In 2014, independent partnerships with the cities of San Francisco and Portland, Oregon, were launched to make it even easier for displaced folks in need of free or discounted short-term accommodations to connect with gracious Airbnb hosts.

Obviously, a kind-hearted stranger's spare bedroom or furnished basement can't replace a home that someone has been evacuated from or lost altogether. But an Airbnb property can offer many of the same comforts: outlets to charge devices, a hot shower, a comfortable bed and a safe and quiet place to sort things out. If anything, post-disaster Airbnb rentals provide solid footing to an individual or family after the proverbial rug has been pulled out from beneath them.

A busy couple of years for altruistic Airbnb hosts

Open Homes program, Airbnb, Hurricane Florence A few zero-dollar Airbnb properties available through the Open Homes platform during Hurricane Florence. Residents displaced by the hurricane can access the listings through the 'find shelter' button on the Open Homes platform. (Photo: Screenshot from Airbnb)

Ideally, the landing page for Open Homes evacuee housing program would be empty, but the last couple of years have proven to be unusual and particularly cruel.

Currently Hurricane Florence evacuees are the focus. Those looking to find a safe place should click the Find Shelter button. There's a separate button for anyone who wants to sign up their home.

In 2017, such "urgent accommodations" were made available in earthquake-ravaged Mexico City; Santa Rosa and other areas of northern California that were impacted by devastating wildfires; and several Caribbean Islands, Puerto Rico included, that suffered mass destruction during hurricanes Maria and Irma.

And for those not living in the Southeast and Mid-Atlantic, it's worth looking more into how Open Homes works and how you can get involved. Judging by the events of the last several years, you never know when big-hearted hospitality might be needed.

Broadening the definition of help to include refugees

Airbnb host and refugee guest in Paris Many Airbnb hosts have opened their homes to refugees via the Open Homes platform. Here, a Parisian Airbnb host chats with his newest guest, a 24-year-old refugee from Cameroon. (Photo: Geoffroy van der Hasselt/AFP/Getty Images)

In June 2017, the Airbnb Disaster Response Tool — described by Fortune as a "quiet side project" — was rebranded and integrated into the larger Open Homes platform with the aid of Cameron Sinclair, formerly of the late, great design-centered humanitarian relief charity, Architecture for Humanity.

Most key features from the previous incarnation of the Disaster Response Tool remain in place. However, in addition to those effected by natural disasters and other large-scale emergencies, the platform was expanded to accommodate refugees and the homeless.

What's more, Open Homes has positioned itself as a resource not just for those directly impacted by catastrophic events but also their families and relief workers. For example, following the act of domestic terrorism in Las Vegas, Open Homes helped victims' families secure zero-cost accommodations in lieu of having to cope with the wallet-draining expense of hunkering down in a hotel for days or weeks at a time. Open Homes played a similar role following the attack in Barcelona, a city that, like other major urban tourist hotspots, has a notably strained relationship with Airbnb.

As for Open Homes' role in housing refugees, that specific feature was prompted by the Trump administration's travel ban on six Muslim-majority countries including war-torn Syria. In February 2017, Airbnb's three founders used the #weaccept hashtag to proclaim:

We believe in the simple idea that no matter who you are, where you're from, who you love, or who you worship, you deserve to belong. We know this is an idealistic notion that faces huge obstacles because of something that also seems simple, but isn't — that not everyone is accepted.
To help people around the world facing displacement, we'll work with our community of hosts to find not just a place to stay, but also a place to feel connected, respected, and a part of a community again.

In the same dispatch, Airbnb announced its intentions to provide short-term housing to 100,000 displaced people like Mousa, an Iraqi refugee profiled in the below video, over the next five years. The company also announced a $4 million donation to the International Rescue Committee to be dispersed over a four-year span.

When Airbnb launched officially launched Open Homes several months later, seven humanitarian organizations — the International Rescue Committee being one of them — were linked into the new platform, making it easier for nonprofits to act as a go-between and directly match refugees with available hosts. As Fast Company pointed out, Open Homes has largely automated the old Disaster Response Tool, which was operated manually by the company "through a hacked together system of emails, phone calls, spreadsheets."

The introduction of the Open Homes platform to the Italian city of Milan has promised to have a particularly strong impact given the record number of migrants that have poured into the city — and Italy as a whole — over the past couple of years. By partnering with local NGOs Refugees Welcome Italia and the community of Sant'Egidio, Airbnb has placed a number of shelter refugees in welcoming and comfortable short-term accommodations.

As for the number of Airbnb hosts in Italy and beyond offering gratis accommodations in times of need, Fortune noted at the launch of Open Homes that there were 6,000 of them spread out across the globe, mainly in the U.S. and Europe. Roughly half of these big-hearted volunteers are existing Airbnb hosts who also rent non-zero-dollar listings to vacationers and business travelers. As for the other half, they simply want to help.

"This is a brand new way for people to contribute and give back in a way that's actually needed the most," explains Airbnb co-founder Joe Gebbia.

Editor's note: This story has been updated since it was originally published in October 2017.

Matt Hickman ( @mattyhick ) writes about design, architecture and the intersection between the natural world and the built environment.

Airbnb's heart shines bright during disasters
The peer-to-peer lodging website's disaster relief tool has been seeing a whole lot of action as of late.