BMW's future is increasingly electrified, but the company isn't yet ready to give up on the internal combustion engine. Watch this drag race from CarWow between a BMW M3 Competition and an i4 M50 to see a duel between the two sides of the German automaker.

The M3 Competition packs a twin-turbo 3.0-litre inline-six making 503 bhp (375 kilowatts or 510 metric hp) and 479 pound-feet (649 Newton-metres) of torque. An eight-speed automatic sends the power to the rear wheels.

Gallery: 2021 BMW M3 Competition: Review

The i4 M50 is an EV with an electric motor on each axle, and they make a total of 536 bhp (400 kW or 544 metric hp). Its battery has an 83.9-kilowatt-hour gross capacity with 81.5 kWh usable. BMW estimates the range at 245 miles (394 kilometres).

The video starts with a best-of-three series of drag races. In the first one, the i4's front wheels spin off the line and give the M3 enough of an advantage to take the win. Next, it's the i4's turn to score a victory, but there's a photo finish because the EV is barely ahead of the M car. The M3 triumphs in the final run.

Next, there are two rolling races from 50 mph (80 kph). Regardless of the driving mode, the result is roughly the same. The i4 leaps ahead, and then the M3 eventually speeds past the EV. However, it's worth noting that the pass happens at around 100 mph (161 kph), which is fast enough to get a hefty traffic ticket in many parts of the world.

There's another rolling race starting from 30 mph (48 kph). The lower starting speed gives the i4 more of an advantage, and it takes the win this time.

The last challenge is a braking test from 100 mph (161 kph). The i4 manages to stop several feet shorter than the performance-focused M3.