There are a lot of things that make iOS great, but lock screen widgets are not among them. If you want more information on your lock screen other than the date, time, and notifications without having to swipe to a sidebar of widgets, you'd normally look toward Android. However, iOS 12 aims to shake that up a bit with a secret Weather widget for the lock screen — not for the Today view.
This widget isn't something Apple publicized much during the keynote presentation at WWDC 2018 or Apple's "Gather Round" event, but you can clearly see it on the screen of an iPhone X when Craig Federighi was talking about gently easing into notifications with Do Not Disturb.
If you're currently running iOS 12 and want this widget to show up on your iPhone pronto, there really isn't much to it. The only downside is that you won't be able to see this Weather widget all the time.
As you could probably guess, it's a part of the Do Not Disturb feature, specifically its "Bedtime Mode." So, you'll only be able to view the widget after a Do Not Disturb session has ended and the iPhone remains locked. Once it's unlocked, the widget will disappear until the end of the next Do Not Disturb cycle.
Because of how the Weather widget works, it requires that the Weather app be allowed to access your location at all times. If you have it set to "While Using the App" or "Never," the Weather widget will never appear on the lock screen.
To make sure it'll work, open the Settings app. Tap "Privacy," then "Location Services" (you can also find this menu by searching for it from the main Settings page). Select "Weather" near the bottom, then ensure "Always" is checked.
Since the widget is only accessible through Bedtime Mode in Do Not Disturb, you'll need to schedule a timeframe for Do Not Disturb and make sure "Bedtime Mode" is toggled on. Once this time ends, the weather widget will appear on your display, with a welcoming wake-up message such as "Good Morning" or "Good Afternoon."
Typically, you'd schedule the time based on when you wake up. However, if you'd like to see the Weather widget right now on your lock screen, set the end time for Do Not Disturb to just one minute past the current time, then lock your iPhone. When you wake your iPhone (not unlock it), the Weather widget should appear on the lock screen. Once you unlock your iPhone, the widget will disappear.
If you don't really care about waking up to a Weather widget or even using Do Not Disturb at all but want to see it during another time of the day, you can just set it for one minute with "Bedtime Mode" on. This way, you're only silencing notifications for 1 minute, which I'm sure is enough for all of you to go without alerts. (We tested zero minutes and that wouldn't work.)
For example, you'd like to see what the weather is like 30 minutes or so before your afternoon jog or stroll through the neighborhood, so you set Do Not Disturb for, say, 2:00–2:01 p.m., with "Bedtime Mode" selected. Then, when you pick up your iPhone in between the end of the Do Not Disturb time and, say, your 2:30 p.m. walk or jog, you'll see exactly what the weather is like before you head outside.
All that's left to do is wake up (if you set it for your actual wake-up time, that is) to your Weather widget! The first time you wake up your iPhone's screen outside of the Do Not Disturb time frame, you'll be greeted by the Weather widget, as well as a "Good [Time of Day/Night]" message.
Of course, once you unlock your iPhone, the widget will disappear until the next scheduled DND time ends. Also, tapping on the widget makes it disappear. Even worse, waking but not unlocking the iPhone, then letting the display go dark again will make it vanish too. So really, you may not even see it sometimes because it comes and goes so quickly.
Hopefully, Apple implements a more permanent Weather widget for the lock screen, but until then, we'll simply keep resetting our Do Not Disturb times based on when we want to see the weather forecast.