Fireworks are colorful explosions against the dark night sky. We love to watch in person, see on TV or look at them in our social media feeds, especially at this time of year. Whether during the Fourth of July, at a sporting event or theme park, or high over a pier at the water’s edge, fireworks seem to make events memorable.

It may seem like it would be easy enough to take a few wonderful photographs of your own to capture the memory of the sky lit up in colors. However, photographing fireworks takes a bit of planning and some basic equipment to get the best results. Here are tips from a professional photographer to help you get that perfect shot.

Use a wide angle: First, you need a camera with a wide-angle lens. Since you are usually fairly close to where the fireworks will be going off, and they burst over a wide area of the sky, this lens is the way to go. A lens wider than 35mm would be best. If you have a wider one, all the better.

Next, you’ll need a tripod to keep your camera steady for a long exposure. You don’t need an expensive one; nearly any tripod will do.

And finally, you’ll want a shutter release cable that fits your camera.

Get your camera ready before the fireworks begin so you aren’t fumbling in the dark trying to figure everything out. You’ll want to put your camera on manual mode so you can set the ISO, shutter speed and f-stop.

As for your tripod, you don’t need to extend the legs all the way. It will be more sturdy lower to the ground and also won’t block anyone’s view if you’re seated in a crowd.

For a fireworks event that I covered, I took a compact tripod in my day pack, a camera and a wide-angle zoom lens. My camera settings were ISO 200, 5 seconds of shutter speed, and f-stop f/11. The long exposure time gives the image long streams of colorful light as well as capturing multiple bursts in the sky.

There is no perfect exposure for fireworks and every situation is different. But in general, a lower ISO setting, in the range of 200-500; a shutter speed of 3 to 6 seconds; and an f-stop ranging from f/5.6 to f/11 should get you in the ballpark for a decent photo. A small flashlight or headlamp could be helpful for you to make small adjustments as you go.

You’ll want to use a shutter release cable so that you are not touching your camera for the long exposure. In place of a shutter cable, you can always set your camera on the self-timer mode — like when you take a photo and then run to get into the shot yourself. This method could be a iffy, since you’ll have to guess when you think the fireworks will go off. Setting the timer at the lowest amount of time would probably be the best since you’re not having to run to get in the photo. It is usually around 2 seconds or so.

Don’t be afraid to shoot lots of photos. You’ll be glad you did, but just be careful not to touch or move the camera.

Frame the scene: The framing can be horizontal or vertical. You’ll want to include some of the surrounding area, not just the explosions against the dark sky. This gives the photograph a sense of place, which always adds dimension.

Use an app: What if you don’t have a professional camera? That’s OK — you can do a pretty good job with a mobile phone too, and the general guidance is the same. Shoot with a slow shutter speed and keep the phone steady.

Both the App Store and Google Play Store have third-party camera apps that allow you to take full control of your camera.

When using a manual camera app, experiment with shutter speeds from 1/30 of a second to 1 second and hold still. If you are using the native camera on iPhone, choose Night Mode. On Android it’s known as Dark Mode or Night Light.

Good luck, and have fun!