The rufous hummingbird (Selasphorus rufus) has found a sweet way to overcome the problem of arriving in its summer breeding grounds ahead of the flowering season.

Flying almost 4,000 miles from Mexico to nest further north than any other hummingbird benefits the rufous hummingbird by offering exclusive access to the wildflowers it feeds on.

But the presence of another bird is likely to allow it to make this unique journey, even when flowers are scarce.

Red-breasted sapsuckers (Sphyrapicus ruber) are woodpeckers that drill rows of small holes into the bark of trees and shrubs. They then use their brush-like tongues to feed on the sap that flows from the holes.

But the sugary sap also attracts hungry hummingbirds to share in the feast.

The behaviour was filmed for the BBC Two programme Alaska: Earth’s Frozen Kingdom in the Tongass National Forest, in southeastern Alaska.

“Rufous hummingbirds migrate very long distances and they must make several, separate flights in succession to complete the journey from wintering to breeding grounds,” says Dr Kenneth Welch, from the University of Toronto Scarborough.

“It seems like they follow the flowering or sap availability as they make this journey.”

They arrive very, very hungry

Weighing as little as 2-5g (0.07- 0.17oz) and flapping their wings at between 52-62 wing beats per second the rufous hummingbird must eat every 20 minutes to satisfy its energy requirements.

“Typically when a hummingbird arrives at a location after a long flight they have exhausted most of their energy reserves,” says Dr Welch.

“They have burned almost all their fat, and even used up some of the protein in their flight muscles. So, they arrive very, very hungry.

“If they don't get some energy quickly, they might not make it through even one day, particularly if it's still cold.”

Several species of hummingbird are known to feed on sap from sapsucker wells and close associations between the two birds have been reported in a number of locations in North America. 

Both sapsuckers and hummingbirds have been shown to defend sap wells suggesting there is serious competition for the resource.

Tree sap is a good substitute for flower nectar with both containing sucrose and amino acids.

Studies have also shown that it can be used as a primary source of energy for hummingbirds and its supply is more reliable and requires less effort to obtain than floral nectar.

It is also thought that the availability of this alternative source of food determines the date hummingbirds arrive in the spring as well as their northern breeding range, with the earlier arrival of sapsuckers being vital to ensure sap is in sufficient supply once the hummingbirds arrive.

Watch the second episode of Alaska: Earth’s Frozen Kingdom at 20:00 GMT, Wednesday 11th February, BBC Two.

You can follow BBC Earth on Facebook, Twitter and Instagram.