What are the main components of the outer core?
Both the outer and inner cores are made mostly of iron and nickel. These are molten in the outer core but high-pressure solids in the inner core.
There are essentially three types of matter from which solid bodies may be formed in space:
Ices are low-temperature solids, like water ice or methane ice, that are low density, volatile, and chemically they are usually made mostly of various combinations of hydrogen, carbon, nitrogen, and oxygen.
Rocks are relatively nonvolatile solids containing heavier elements, typically (at least in our Solar System) made mostly of oxygen, silicon, and various metals like sodium, magnesium, aluminum, calcium, and iron. Rocks differ from ices in that they remain solid at high temperatures and thus may exist relatively close to stars, for example on Earth. They may be liquified, however, inside the hot interiors of large bodies like Earth.
Metals are the densest type of solid matter in space. They are made of generally heavier metals that are not chemically combined. The most common metallic elements that remain uncombined, at least in our Solar System, are iron followed by nickel. Like rocks, metals may be liquid deep inside the hot interiors of large bodies, as we see in the structure of Earth.
With their high density, metals tend to sink downward/inward in large solid bodies under gravity when the solid bodies are freshly formed and hot (a process called differentiation, https://en.wikipedia.org/wiki/Planetary_differentiation). So the iron-and nickel-rich metals end up overwhelmingly in the core. In the case of Earth we know that in part of the core the metal is melted (outer core), but inside that liquid is high-pressure solid metal (inner core).