Users have been locked out of their accounts after falling for the trick (Image: AFP)

A worrying WhatsApp scam has been reported by frustrated users - with people locked out of their accounts after being taken in by the trick.

People say they have received messages claiming to be after a six-digit code - with those who do get it urged to delete it.

Victims receive a message seemingly from a friend which states: "Hello, sorry, I sent you a 6-digit code by mistake, can you pass it to me please? It's urgent?"

In fact, the Express reports, a code, which is sent alongside the message, gives criminals access to your account.

Whenever anyone upgrades their handset, WhatsApp generates a six digit code so you can get hold of messages archived in your chat.

This is sent in a text message.

WARNING: WHATSAPP SCAM 3 members of my family have lost access to their WhatsApp this morning! Hackers send a text message from WA with a verification code, then a WhatsApp text from someone you know saying they desperately need the code. DO NOT SEND THE CODE OR CLICK THE LINK pic.twitter.com/T8dqPydH3N

— Tommy Wathen (@tommywathen) May 18, 2021

If you hand this over, it means someone else can access your messages - leaving you locked out of WhatsApp, victims say.

One WhatsApp user posted on Twitter : "Three members of my family have lost access to their WhatsApp this morning.

"Hackers send a text message from WA with a verification code, then a WhatsApp text from someone you know saying they desperately need the code. Do not send the code or click the link."

People who have been taken in by the scam include Radio 2 presenter Jeremy Vine, who said criminals had been able to use his contact list to target more people.

Ray Walsh, Digital Privacy Expert at ProPrivacy, told the Express: "WhatsApp users need to be on the lookout for a worrying new scam that is allowing cybercriminals to hack into people’s WhatsApp accounts.

"Anybody who receives a message out of the blue with a one-time PIN code should be extremely wary because this is how the attack starts.

"Following the receipt of the unexpected OTP code, the hacker will send the victim a direct message claiming to be their friend or contact. They will then ask to be forwarded the code by claiming to have mistakenly sent it to them.

"That code is actually the two-factor authentication code for accessing the victim's WhatsApp account, and once the victim forwards it to the hacker they will use it to hack into their account.

"Always be on the lookout for any text messages that contain an OTP code and never, ever forward or screenshot or otherwise pass those codes on to anybody, no matter how genuine they sound."