



Freepik API uses Magnific.ai technology, now available as a comprehensive API service.
- A prompt
- A reference image
- A light map
Use Cases
The Image Relight can be applied to a wide range of image types and industries, including:- Portraits: Change lighting to enhance facial features
- Product photography: Adjust lighting for better presentation
- Architectural renderings: Simulate different times of day
- Film stills: Create dramatic lighting effects
- Graphic design: Add creative lighting to designs
- Nature photography: Enhance natural light conditions
Selecting Light Transfer Method
Choose one of these three ways to transfer light in Image Relight:- Prompt Describe the desired lighting using text. Specify characteristics like color, time of day, type and shape of light. Example: “A sunlit forest clearing at golden hour” or “Under the water”
- Reference Image Provide an image to transfer lighting from. Image Relight will replicate the light, colors, and shadows from this reference.
-
Lightmap Create custom lighting with your own lightmap image:
- Black represents absence of light
- Lighter colors (including white) indicate presence, color, and shape of light sources
POST /v1/ai/image-relight
Relight an image using AI
GET /v1/ai/image-relight/{task-id}
Get the status of a relighting task
GET /v1/ai/image-relight
Get the status of all relighting tasks
Image Input Best Practices
For maximum quality results, how you send your image matters:| Action | Quality Impact |
|---|---|
| Send URL of original image | ✅ Maximum quality |
| Send base64 of original file read directly | ✅ Maximum quality |
Use canvas.toDataURL('image/jpeg') | ❌ ~8% quality loss |
Use canvas.toDataURL('image/jpeg', 0.8) | ❌ ~20% quality loss |
| Resize image before sending | ❌ Significant quality loss |
| Convert PNG → JPEG before sending | ❌ Quality loss |
Frequently Asked Questions
Is this the same technology as Magnific.ai?
Is this the same technology as Magnific.ai?
Yes! Magnific.ai is part of Freepik and we are happy to offer the same technology in an API service. If you tried Magnific.ai before, you will get the same technology and its future updates.
How much does the image relight cost?
How much does the image relight cost?
The cost per image relight is a fixed cost of €0.10 per operation. This ensures that you have complete transparency and control over your usage.