My camera, the D850, actually has a built-in feature for recording time-lapse videos, but there’s another way: Taking stills every couple of seconds and make them into a video in post processing.
What the heck?
Why would anyone in their right mind prefer taking stills and wasting time in post? Well, you probably shoot in RAW, don’t you? And for good reason. Shooting a time-lapse video in-camera vs taking stills and making them into a video is very much like JPEG vs RAW: You stay in control and have all the options available to you in post.
This becomes particularly important when shooting a sunrise or sunset, because the light changes rapidly and, presuming you’re shooting in aperture priority, your shutter time will get close to (and surpass) the interval time really fast, at which point you’ll be losing frames. Of course, you could just shoot in manual and shoot at the same settings for the whole duration, but that will bite you in post when you’re desperately trying to fix the underexposed parts of your video.
Also, I use an external intervalometer for my time-lapses, it’s just too much hassle to flip through the camera menus when I need to start or stop the recording.
Now, taking hundreds of stills in a row will contribute to rapid shutter wear, unless you have an electronic shutter. The D850 features both, the electronic shutter is available in Live View (silent mode) so that’s what I use when shooting a time-lapse video.
Make sure you are using the electronic shutter if you have it. I wouldn’t recommended using this technique with a mechanical shutter, if you do, do so at your own risk.