A 12-year-old boy is in a stable condition after he was allegedly stabbed in the chest on Monday night in the north-western New South Wales town of Bourke.

NSW police said the child was allegedly attacked outside a home in Hamilton Place around 6pm.

The boy was rushed to Bourke hospital before being airlifted to the Children’s hospital at Westmead, where he remains.

Police arrested a 24-year-old Mount Austin man on Monday night and charged him with wounding a person with intent to cause grievous bodily harm.

He was due to appear in Bourke local court on Tuesday.