Skip to content
Switch branches/tags
Go to file
Cannot retrieve contributors at this time



PRs welcome code with hearth by dukeofharen pipeline status

Table of Contents


HttPlaceholder lets you stub away any HTTP webservice.

It was thought up while I was working at a company which had many interconnected webservices. The development process was very painful, because it meant all the other webservices should also be started on my local dev PC, or I had to use the "development" environment, which did not work for half of the time. HttPlaceholder fills this gap nicely.


  • can easily be installed on your dev PC.
  • can be used to easily create stubs, either as separate YAML files, through the API or through the user interface.
  • can easily be hosted on any server.
  • can use many different HTTP condition checkers and response writers to make your HTTP stubs as specific as you need.

Built With

Getting Started


Linux, Windows and Mac are supported.


Install on Windows

Set-ExecutionPolicy Bypass -Scope Process -Force; iex ((New-Object System.Net.WebClient).DownloadString(''))

Install on Linux

sudo curl -o- | sudo bash

Install on Mac

sudo curl -o- | sudo bash

Install as .NET tool

dotnet tool install --global httplaceholder


  • Install HttPlaceholder (see Installation).
  • Create a new .yaml file (e.g. stub.yaml).
  • Copy and paste these contents in your new file:
- id: situation-01
    method: GET
      path: /users
        id: 12
        filter: first_name
    statusCode: 200
    text: |
        "first_name": "John"
      Content-Type: application/json
  • Open the terminal in the folder you've added the stub.yaml file and run the following command: httplaceholder. HttPlaceholder will now start and will load the stubs in the current folder.

  • Perform a specific HTTP call to HttPlaceholder so your provided response will be returned.

    • For Linux / Mac (cURL needs to be installed): curl "http://localhost:5000/users?id=12&filter=first_name" -D-
    • For Windows (uses Powershell): (Invoke-WebRequest "http://localhost:5000/users?id=12&filter=first_name").RawContent
  • You can view and inspect the performed requests in the user interface at http://localhost:5000/ph-ui.

For more sophisticated examples, go to the page samples to view samples for all supported HTTP condition checkers and response writers.




See the open issues for a list of proposed features (and known issues).


Reach out to the maintainer at one of the following places:

Project assistance

If you want to say thank you or/and support active development of HttPlaceholder:


First off, thanks for taking the time to contribute! Contributions are what make the open-source community such an amazing place to learn, inspire, and create. Any contributions you make will benefit everybody else and are greatly appreciated.

We have set up a separate document containing our contribution guidelines.

Thank you for being involved!

Authors & contributors

The original setup of this repository is by dukeofharen.

For a full list of all authors and contributors, check the contributor's page.


HttPlaceholder follows good practices of security, but 100% security can't be granted in software. HttPlaceholder is provided "as is" without any warranty. Use at your own risk.

For more info, please refer to the security.


This project is licensed under the MIT license.

See LICENSE for more information.