Fetch API helps to make HTTP requests using fetch(). You can post data to an API by passing in the API url to fetch method along with the data in the body. `fetch` method is available in the window as a global function. In this JavaScript tutorial you'll learn how to post data to an API using fetch.