NEW YORK — Volkswagen will invest $2.6 billion into a Pittsburgh autonomous vehicle company that’s mostly owned by Ford as the automakers who were once rivals deepen their partnership to develop driverless and electric vehicles in an ultra-competitive landscape.

The two automakers will become equal owners of Argo AI, and they plan to put autonomous vehicles on the roads in the U.S. and Europe as early as 2021, the companies said Friday.

The deal also includes a plan for Ford to use VW’s electric vehicle platform to build zero-emissions cars for the European market starting in 2023.

Auto companies have been teaming up with each other as well as with big technology firms over the past few years to try to spread out the enormous costs of developing self-driving and electric vehicles.

Ford CEO Jim Hackett expects the large crowd of players to be narrowed down.