Why Do Videos End Up Sideways or Upside Down?
We have all been there: you record a great video on your phone, transfer it to your computer, and suddenly it is playing sideways. This happens because smartphones embed orientation metadata (EXIF rotation flags) into the video file rather than physically rotating the pixel data. When a media player ignores that metadata, your perfectly composed landscape shot ends up displayed in portrait mode, or worse, completely upside down.
Understanding the difference between metadata rotation and actual pixel rotation is the first step to fixing the problem. In this guide, we will cover every method for rotating and flipping videos, from quick online tools to powerful command-line solutions using FFmpeg.

Rotation vs. Flipping: What Is the Difference?
Before diving into methods, let us clarify these two distinct operations:
Rotation changes the angle of the entire frame. You rotate a video by a fixed number of degrees, typically 90, 180, or 270 (which is the same as -90). The frame dimensions swap when rotating 90 or 270 degrees: a 1920x1080 video becomes 1080x1920.
Flipping (also called mirroring) reverses the video along an axis. A horizontal flip creates a mirror image (left becomes right), while a vertical flip turns the video upside down without swapping sides.
| Operation | What Changes | Dimensions | Common Use Case |
|---|---|---|---|
| Rotate 90° CW | Frame turns clockwise | Width/height swap | Portrait to landscape |
| Rotate 180° | Frame turns upside down | Same | Inverted camera mount |
| Rotate 270° CW | Frame turns counter-clockwise | Width/height swap | Landscape to portrait |
| Flip Horizontal | Left-right mirror | Same | Selfie camera correction |
| Flip Vertical | Top-bottom mirror | Same | Inverted footage |
Pro Tip: If your video appears mirrored (text reads backwards), you need a horizontal flip, not a rotation. Front-facing cameras on phones often mirror the preview but save the correct orientation, so check the actual file before making changes.
Method 1: Rotate and Flip Videos Online (Fastest)
The quickest way to fix video orientation is with an online tool. ConvertIntoMP4 offers a dedicated Rotate Video tool that handles rotation and flipping directly in your browser with no software installation needed.
Steps to Rotate Video Online
- Go to the Rotate Video tool page
- Upload your video file (supports MP4, MOV, AVI, MKV, WebM, and more)
- Select your rotation angle: 90°, 180°, or 270° clockwise
- Choose flip options if needed (horizontal or vertical)
- Click Rotate and download the corrected file
This method works on any device with a web browser, including phones, tablets, and Chromebooks. For additional format conversion during the process, use the full Video Converter which combines rotation with format output selection.
Online Tool Comparison
| Feature | ConvertIntoMP4 | Tool B (Generic) | Tool C (Generic) |
|---|---|---|---|
| Max File Size | 500 MB (free) | 100 MB | 250 MB |
| Rotation Options | 90°/180°/270° + Flip | 90°/180°/270° | 90° only |
| Output Formats | MP4, MOV, AVI, WebM | MP4 only | MP4, MOV |
| Batch Processing | Yes | No | No |
| Quality Preservation | Lossless option | Re-encodes always | Re-encodes always |
| Speed | Fast (cloud processing) | Moderate | Slow |
Method 2: Using FFmpeg (Command Line)
FFmpeg is the industry-standard tool for video manipulation. It gives you granular control over rotation, flipping, and quality settings.
Rotate 90 Degrees Clockwise
ffmpeg -i input.mp4 -vf "transpose=1" output.mp4
The transpose filter accepts these values:
0— Rotate 90° counter-clockwise and flip vertically1— Rotate 90° clockwise2— Rotate 90° counter-clockwise3— Rotate 90° clockwise and flip vertically
Rotate 180 Degrees
ffmpeg -i input.mp4 -vf "transpose=1,transpose=1" output.mp4
Or more efficiently using the hflip and vflip combination:
ffmpeg -i input.mp4 -vf "hflip,vflip" output.mp4
Rotate 270 Degrees (90° Counter-Clockwise)
ffmpeg -i input.mp4 -vf "transpose=2" output.mp4
Flip Horizontally (Mirror)
ffmpeg -i input.mp4 -vf "hflip" output.mp4
Flip Vertically
ffmpeg -i input.mp4 -vf "vflip" output.mp4
Combine Rotation and Flip
You can chain filters together. For example, rotate 90° clockwise and then flip horizontally:
ffmpeg -i input.mp4 -vf "transpose=1,hflip" output.mp4
Pro Tip: To avoid re-encoding and preserve original quality, use the metadata rotation approach instead of pixel manipulation. This command sets the rotation flag without touching the video stream:
ffmpeg -i input.mp4 -c copy -metadata:s:v rotate="90" output.mp4
However, not all players respect metadata rotation, so pixel-level rotation is more reliable for sharing.

Method 3: Lossless Rotation with Metadata
Many modern video files already contain orientation metadata. Instead of re-encoding the entire video (which takes time and can reduce quality), you can modify just the metadata flag. This is nearly instantaneous and completely lossless.
How Metadata Rotation Works
Video containers like MP4 and MOV support a rotation matrix or display rotation tag. When you set this tag, compatible players automatically orient the video correctly during playback.
# Remove existing rotation and set new rotation to 90°
ffmpeg -i input.mp4 -c copy -metadata:s:v:0 rotate=90 output.mp4
Limitations of Metadata Rotation
While metadata rotation is lossless and fast, it has some drawbacks:
- Not all video players or editors respect the rotation tag
- Social media platforms may ignore the flag during upload processing
- Some older software strips the metadata during editing
- Thumbnail generation may not reflect the rotation
For maximum compatibility, especially when sharing on social media platforms or uploading to services, pixel-level rotation is the safer choice.
Method 4: Rotating Videos on Mobile Devices
iOS (iPhone and iPad)
The built-in Photos app on iOS lets you rotate videos:
- Open the video in Photos
- Tap Edit in the top right
- Tap the Crop/Rotate icon (square with arrows)
- Tap the rotate button to rotate 90° at a time
- Tap Done to save
Android
Google Photos (pre-installed on most Android devices) supports rotation:
- Open the video in Google Photos
- Tap Edit
- Tap Crop
- Use the rotation icon to rotate in 90° increments
- Tap Save copy
For more advanced mobile editing, including format conversion, check out our guide on how to convert MOV to MP4 which covers mobile workflows.
Batch Rotation: Fixing Multiple Videos at Once
If you have dozens of sideways videos from a shoot, rotating them one by one is tedious. FFmpeg makes batch rotation straightforward.
Bash Script for Batch Rotation
#!/bin/bash
# Rotate all MP4 files in current directory 90° clockwise
mkdir -p rotated
for file in *.mp4; do
ffmpeg -i "$file" -vf "transpose=1" -c:a copy "rotated/$file"
echo "Rotated: $file"
done
Using ConvertIntoMP4 for Batch Processing
Our batch processing feature lets you upload multiple videos and apply the same rotation to all of them simultaneously. This is especially useful when combined with format conversion, for example, rotating and converting a folder of MOV files to MP4 in one step.
For detailed batch workflows, see our complete batch processing guide.

Quality Considerations When Rotating Video
Rotation can be either lossless or lossy depending on your method:
Lossless Methods
- Metadata rotation — Changes only the orientation flag, zero quality loss
- Stream copy with rotation — Uses
-c copyflag in FFmpeg - Container remuxing — Changes the container without touching video data
Lossy Methods (Re-encoding Required)
- Pixel-level rotation — The
transpose,hflip, andvflipfilters require decoding and re-encoding - Format conversion with rotation — Converting from one codec to another while rotating
When re-encoding is unavoidable, use high-quality settings to minimize degradation:
# High-quality rotation with H.264
ffmpeg -i input.mp4 -vf "transpose=1" -c:v libx264 -crf 18 -preset slow -c:a copy output.mp4
# High-quality rotation with H.265 (smaller file)
ffmpeg -i input.mp4 -vf "transpose=1" -c:v libx265 -crf 22 -preset slow -c:a copy output.mp4
For a deep comparison of codec options, read our guide on H.265 vs H.264 vs AV1.
CRF Values for Rotation Re-encoding
| Codec | Visually Lossless | High Quality | Balanced | Smaller File |
|---|---|---|---|---|
| H.264 (libx264) | CRF 15-17 | CRF 18-20 | CRF 21-23 | CRF 24-28 |
| H.265 (libx265) | CRF 18-20 | CRF 21-23 | CRF 24-26 | CRF 27-32 |
| AV1 (libaom) | CRF 20-23 | CRF 24-28 | CRF 29-32 | CRF 33-40 |
Understanding how these quality settings work is essential for maintaining video fidelity. Check our guide on compressing video without losing quality for additional strategies.
Common Rotation Scenarios and Solutions
Scenario 1: iPhone Video Plays Sideways on Windows
iPhones record in a fixed sensor orientation and rely on metadata to tell the player how to display the video. Windows Media Player historically had poor metadata support.
Fix: Use the Rotate Video tool to apply a pixel-level 90° rotation, then save as MP4. This ensures universal compatibility across all players.
Scenario 2: Screen Recording Is Upside Down
Some screen recording software (particularly on Linux or with external capture cards) may produce inverted footage.
Fix: Apply a 180° rotation using FFmpeg:
ffmpeg -i screencast.mp4 -vf "hflip,vflip" -c:a copy fixed_screencast.mp4
Scenario 3: Webcam Mirror Effect Needs Correction
Webcams and front-facing cameras often mirror the image so it feels like looking in a mirror. For presentations or tutorials, you may want the text and gestures to appear correctly oriented.
Fix: Apply a horizontal flip:
ffmpeg -i webcam_recording.mp4 -vf "hflip" -c:a copy corrected.mp4
Scenario 4: Drone Footage Orientation
Gimbal-mounted drone cameras sometimes record with incorrect orientation metadata, especially after firmware updates or mid-flight angle changes.
Fix: Check the actual orientation first, then apply the appropriate rotation. For drone footage that needs format conversion as well, the Video Converter handles both operations in a single pass.
Preserving Aspect Ratio During Rotation
When rotating by 90° or 270°, the video dimensions swap. A 1920x1080 (16:9) video becomes 1080x1920 (9:16). This is usually the desired behavior, but if you need to maintain the original dimensions, you can add padding:
# Rotate 90° and add black bars to maintain 1920x1080
ffmpeg -i input.mp4 -vf "transpose=1,pad=1920:1080:(ow-iw)/2:(oh-ih)/2:black" output.mp4
For more on aspect ratio management and cropping, see our guide on how to resize video and use the Crop Video tool for visual cropping controls.
Choosing the Right Format After Rotation
After rotating your video, you will want to save it in the best format for your use case. Here is a quick reference:
| Use Case | Recommended Format | Why |
|---|---|---|
| General sharing | MP4 (H.264) | Universal compatibility |
| High quality archive | MP4 (H.265) or MKV | Better compression |
| Web embedding | WebM (VP9) | Optimized for browsers |
| Social media | MP4 (H.264) | Required by most platforms |
| Professional editing | MOV (ProRes) | Preserves editing quality |
For detailed format comparisons, read our comprehensive best video formats guide and check the platform-specific requirements in our social media video specs guide.
Frequently Asked Questions
Does rotating a video reduce quality?
Only if re-encoding is involved. Metadata rotation and stream copy methods are completely lossless. When re-encoding is needed, using a low CRF value (e.g., CRF 18 for H.264) preserves nearly all visible quality.
Can I rotate a video without re-encoding?
Yes, by using metadata rotation (-metadata:s:v rotate="90" in FFmpeg) or the -c copy flag. However, not all players support metadata rotation, so test with your target platform first.
How do I rotate a video on my phone?
Both iOS Photos and Google Photos on Android have built-in rotation tools. Open the video, tap Edit, and use the rotation controls. For more options, upload to the Rotate Video tool from your mobile browser.
What is the difference between rotating and transposing?
In FFmpeg terminology, transposing combines rotation with an optional flip in a single operation. The transpose filter is more efficient than chaining separate rotate and flip filters.
Conclusion
Fixing video orientation is one of the most common video editing tasks, and fortunately it is also one of the simplest. For quick one-off fixes, use the Rotate Video tool directly in your browser. For batch processing or integration into automated workflows, FFmpeg provides all the flexibility you need.
Remember to choose lossless rotation methods when possible, and when re-encoding is necessary, use quality settings that match your output requirements. With the techniques covered in this guide, you will never be stuck with a sideways video again.
Need to do more with your videos? Check out our Video Converter for format conversion, the Video Trimmer for cutting clips, or the Video Compressor for reducing file sizes.



