Back to Blog

Seamlessly Create Picture-in-Picture Videos with FFMPEGAPI.net

June 2026 FFMPEG API Team

In today's digital landscape, creating engaging video content is essential. One popular technique is the picture-in-picture (PiP) effect, which allows you to overlay one video on top of another. With FFMPEGAPI.net's fast media processing API, developers can easily implement this feature without the hassle of server setup or FFmpeg infrastructure management. This article will guide you through creating a picture-in-picture video using our hosted API.

What is Picture-in-Picture?

Picture-in-picture (PiP) is a video effect that overlays a smaller video on top of a larger background video. This technique is widely used in tutorials, broadcasts, and creative content to enhance viewer engagement.

Why Choose FFMPEGAPI.net?

FFMPEGAPI.net provides a hosted REST API specifically designed for FFmpeg-powered video and audio processing. Here are some reasons why it's the best choice for developers:

1. No server setup or FFmpeg infrastructure management required.

2. API-key authentication ensures secure access for your developer workflows.

3. Perfect for automation, SaaS apps, content pipelines, or AI agents.

How to Use the Picture in Picture API

The Picture in Picture API allows you to overlay one video on another by configuring parameters such as position, scale, and audio source.

  • Endpoint: POST /api/picture_in_picture
  • Content-Type: application/json
  • Required parameters: main_video_url, pip_video_url
  • Optional parameters: position, scale, audio_option, async
curl -X POST https://www.ffmpegapi.net/api/picture_in_picture \ 
-H "Content-Type: application/json" \ 
-d '{"main_video_url":"https://example.com/main.mp4", "pip_video_url":"https://example.com/overlay.mp4", "position":"top-right"}'

API Parameters Explained

Here’s a quick overview of the parameters you can use with the Picture in Picture API:

1. **main_video_url**: The URL of the main/background video (required).

2. **pip_video_url**: The URL of the overlay/PiP video (required).

3. **position**: Where to position the overlay (optional, defaults to bottom-right).

4. **scale**: FFmpeg scale expression for the overlay (optional, defaults to iw/4:ih/4).

Creating picture-in-picture videos is now simpler than ever with FFMPEGAPI.net. With just a few API calls, you can enhance your video content and elevate the viewing experience. Whether you're building automation tools, SaaS applications, or content pipelines, our fast media processing API is the perfect solution for all your video overlay needs. Start leveraging the power of FFmpeg in your projects today!

Ready to Start Processing Videos?

Get your free API key and start merging videos in minutes

Get Started Free