If you need furniture for your apartment, there's an app for that. When you want alcohol delivered to your door, there are about 10 apps for that. And if you need laundry dropped off, your winter wardrobe put into storage, or a fresh supply of medical marijuana, there are dozens of apps that offer those services.

Indeed, the on-demand economy has given birth to hundreds of companies that offer the ease and convenience of home delivery for the things you're too lazy to get or do yourself. But how do all these companies handle the logistics of getting a product or service from a local merchant to the smartphone-clutching customer waiting at home? Increasingly, they're turning to yet another startup: San Francisco-based delivery-management software provider Onfleet.

Founded by a Stanford business school student, a Stanford computer science dropout, and a University of New Brunswick computer science grad, Onfleet powers thousands of deliveries every day for apps like HelloFresh, which delivers recipes and premeasured fresh ingredients to prepare them; TopShelf, an Austin-based beer, wine, and liquor delivery service;  Meadow and Canary, which deliver medical marijuana; and Lugg, provider of on-demand moving. Onfleet's software connects local merchants and delivery apps with networks of couriers and drivers, and manages the deliveries, forming the backbone of the on-demand economy.

Integrated into these on-demand apps, the software helps the companies delegate jobs to their delivery fleet or to third-party courier services, communicate with their customers when a driver is on the way, and track orders in real time. The company, which was founded by David Vetrano, Mikel Carmenes Cavia, and Khaled Naim in 2012, had been in stealth mode until late April when it publicly launched with a $2 million funding round from Winklevoss Capital, CrunchFund, and Stanford-StartX Fund, as well as several angel investors. 

Customers in 25 countries have been using Onfleet's beta version since January 2014. With thousands of drivers on the road using its software, Onfleet is not yet profitable but is generating revenue managing hundreds of thousands of deliveries. "Businesses use their own fleet for delivery, but it's our software that connects the dots and breaks down barriers of private fleets," says Naim, who is also Onfleet's CEO.

Onfleet's software-as-a-service product charges companies each month on the basis of how many deliveries they make.The software is free for companies that do 75 deliveries or fewer a month, but many do far more than that; Onfleet's largest client does more than 100,000.

Naim was born in the U.S., but his family soon moved to London and later settled in Dubai. With parents who were in real estate and oil, he witnessed the boomtown expansion of commerce in the region. He says when delivery services started to become popular, it threw the postal system off. "Street addresses in the Middle East are either nonexistent or very difficult to communicate," he says. "If you order food, you provide your phone number and the driver calls you when he's on the way. It isn't very efficient."

After Naim returned to the U.S. to get his MBA at Stanford, he met Vetrano and brought in Cavia, whom he knew from high school. In 2012, the trio built Addy--a startup letting users share their exact address with a simple URL that links to a map with directions and notes--at Stanford's accelerator program, StartX. It was a rough prototype, but they had paying customers almost right away.

As the on-demand economy started to blossom, they found that startup delivery apps were trying to reinvent the wheel each time when it came to software logistics layers--driver apps, real-time tracking, and communication with customers. In December 2013, they decided to tweak Addy's capabilities to cater to those companies, and Onfleet was born. "We decided to make a [programming interface] for all these companies," Naim says. "That way they can scale their services faster without building software that has already been built." 

Onfleet's business-to-business model is meant to help local merchants big and small get into the on-demand delivery space. By offering an easy software service to take care of the last-mile of delivery management, Onfleet has its sights on becoming as big as Uber.

"It's super expensive to do delivery--you have to hire drivers, manage deliveries, and analyze data," Naim says. "Our goal is to build a billion-dollar company. We want to be the world's delivery network."