Cross-posted my answer here.
It is Sir William R. Hamilton who originally touched upon the concept. Near the end of his letter to John T. Graves about his recent discovery of quaternions in the same year (1843), he writes the following:
Multiplication will be easy if we are familiar with the rules for the product of two pure imaginaries. This product is, by (B.),
$$(0, b, c, d)(0, b′, c′, d′) = (−bb′ − cc′ − dd′, cd′ − dc′, db′ − bd′, bc′ − cb′);$$
the product-line is perpendicular to the plane of the factors; its length is the product of their lengths multiplied by the sine of the angle between them: and the real part of the product, with its sign changed, is the same product of the lengths of the factors multiplied by the cosine of their inclination.
In essence, he recognized that (using modern notation for quaternions):
$$(0, \vec{v})(0, \vec{w}) = (-\Vert \vec{v} \Vert \Vert \vec{w} \Vert \cos(\theta), \Vert \vec{v} \Vert \Vert \vec{w} \Vert \sin(\theta) \vec{k})$$
where $\theta$ is the angle between $\vec{v}$ and $\vec{w}$, and $\vec{k}$ is perpendicular to $\vec{v}$ and $\vec{w}$.
This discovery precedes Gibbs and Heaviside, who were born in 1839 and 1850 respectively.