Development
This document gets you up and running for Owncast development. If you want more on contributing in non-technical ways too, read the Contributor Guide.
Owncast is a straightforward web application and, compared to many projects, is easy to get running locally.
Web frontendโ
The frontend is the interface you interact with: the player, chat, and all the components on the page. It also includes the Owncast admin where the server is configured. It is written in TypeScript and built with React and Next.js. See "How we develop frontend components" for the patterns we follow.
Backendโ
The backend powers the features and functionality: the video pipeline, web server, chat service, inbound RTMP server, ActivityPub/Fediverse integration, and more. You may also want to read how our APIs are built in "API / Web Routing Development".
Set up your development environmentโ
- Fork the Owncast repository on GitHub at https://github.com/owncast/owncast.
- Clone your fork:
git clone https://github.com/yourusername/owncast.
Run the backend serverโ
- Install the Go tools for your system.
- Install ffmpeg, available either globally or in the same directory as the Owncast code.
- A C compiler and its development libraries must be available, usually
gcc. - Run
go run main.gofrom the root of the repository.
We lint Go with golangci-lint. It is optional but useful.
Run the frontendโ
- Change to the
webdirectory and install dependencies withnpm install. - Start the dev server with
npm run dev. - Open http://localhost:3000.
We format and lint with Prettier and ESLint. Linting or formatting errors will block a PR until they are fixed.
Use Storybook for React componentsโ
Storybook lets you build and test components in isolation, without running a full Owncast server. A hosted copy of our components is at https://owncast.online/components.
- Run
npm run storybook. - Open http://localhost:6006.
Translationsโ
Any hard-coded text in the frontend must support translations. See the Owncast Translation Guide for how to do this.
Run a development streamโ
Many features only turn on when a stream is live. Run a local test stream with ./test/ocTestStream.sh from the repo root.
Make your changesโ
Create a branch for your work: git checkout -b my-new-feature.
Find a starter taskโ
Browse GitHub Issues labeled "good first issue" with no assignee for a good place to start.