Kanun Keseksaan
Applies to: Federal (whole of Malaysia); revised as Act 574 in 1997 · Official text ↗
- The Code defines offences and sets maximum (and sometimes minimum) punishments. The court chooses the sentence within those limits.
- General exceptions (ss 76 to 106) can excuse conduct: for example a child under 10 cannot commit an offence, and a person acting in lawful private defence is protected.
- Cheating (s 420) and criminal breach of trust (s 406) are serious offences carrying imprisonment, whipping and a fine. Cheating under s 420 carries a minimum of one year in prison.
- Stalking became a specific offence under s 507A from 31 May 2023 (up to 3 years, fine, or both). Bullying and harassment offences (ss 507B to 507G) followed from 11 July 2025.
- The mandatory death penalty was abolished from 4 July 2023. For murder and other formerly mandatory offences the court may now choose between death and 30 to 40 years' imprisonment.
- Attempted suicide is no longer a crime: s 309 was repealed with effect from 10 September 2025. Abetting suicide is still an offence.
What this law covers
The Penal Code (Kanun Keseksaan) is the main source of criminal offences in Malaysia. It dates from the colonial period (based on the Indian Penal Code of 1860) and was revised as Act 574. It is federal law and applies to every person, Muslim or non-Muslim, for offences committed in Malaysia, and in some cases outside it. Many other offences are in separate Acts, such as the Dangerous Drugs Act 1952, the Communications and Multimedia Act 1998 and the Road Transport Act 1987. Syariah criminal offences for Muslims are in State laws (see Syariah Criminal Offences (Federal Territories) Act 1997).
How a case is investigated, charged and tried is governed by the Criminal Procedure Code, and what evidence can be used by the Evidence Act 1950.
Structure of the Code
- Chapters I to III: title, territorial reach, definitions (for example "dishonestly", "fraudulently", "public servant") and the kinds of punishment: death, imprisonment, whipping, fine and forfeiture.
- Chapter IV, General Exceptions (ss 76 to 106): defences that apply to all offences.
- Chapters V and VA: abetment and criminal conspiracy.
- Chapters VI onwards: specific offences, grouped by type: against the State, public tranquillity, public servants, false evidence, public health and safety, religion, the human body (murder, hurt, kidnapping, sexual offences), property (theft, extortion, robbery, criminal breach of trust, cheating, mischief, trespass), documents, marriage, defamation, and criminal intimidation, insult and annoyance.
- Attempts (s 511): attempting an offence is generally punishable with up to half the longest term of imprisonment for the offence.
Each offence is set out as a definition section followed by a punishment section, often with explanations and illustrations. For example, s 415 defines cheating and s 420 punishes the most serious form of it.
General exceptions (defences)
Nothing is an offence if it falls within a general exception. The main ones are:
- Mistake of fact (ss 76 and 79): acts done by a person who, through a mistake of fact made in good faith, believes they are bound or justified by law. Ignorance of the law is not a defence.
- Accident (s 80) in doing a lawful act in a lawful manner with proper care.
- Children (ss 82 and 83): nothing done by a child under 10 is an offence. A child aged 10 to under 12 is not liable if they had not reached sufficient maturity to understand the nature and consequences of the act.
- Unsoundness of mind (s 84): no offence if, because of unsoundness of mind, the person did not know the nature of the act or that it was wrong or contrary to law.
- Intoxication (ss 85 and 86): a defence only in limited cases, such as involuntary intoxication or where it caused insanity.
- Consent (ss 87 to 92) in limited situations, such as medical treatment in good faith.
- Duress (s 94): limited; not available for murder or offences against the State punishable with death.
- Private defence (ss 96 to 106): you may defend your body, or another person's, against an offence affecting the body, and property against theft, robbery, mischief or criminal trespass. The harm caused must not be more than necessary (s 99). Causing death is justified only in serious cases listed in s 100 (for example reasonable fear of death, grievous hurt, rape) and s 103.
The accused must prove a general exception relied on (Evidence Act 1950, s 105).
Common offences people ask about
| Offence | What it means | Punishment |
|---|---|---|
| Theft (curi), ss 378 and 379 | Dishonestly taking movable property out of another's possession without consent. | Up to 7 years, or fine, or both. Theft of a motor vehicle (s 379A) carries 1 to 7 years and a fine. |
| Voluntarily causing hurt (mendatangkan kecederaan), ss 319 and 323 | Causing bodily pain, disease or infirmity. | Up to 1 year, or fine up to RM2,000, or both. Heavier for dangerous weapons (s 324) and grievous hurt (ss 320, 325, 326). |
| Criminal breach of trust (pecah amanah jenayah), ss 405 and 406 | Dishonestly misappropriating or converting property entrusted to you, such as money given for a purpose, or an employer's funds. | Imprisonment up to 10 years, with whipping, and a fine. Heavier by public servants, bankers, agents and others (s 409: 2 to 20 years and whipping). |
| Cheating (menipu), ss 415 and 420 | Deceiving someone, fraudulently or dishonestly, to deliver property or to do or omit something they would not otherwise do, causing or likely to cause harm. Section 420 covers cheating that induces delivery of property. | s 420: 1 to 10 years, with whipping, and a fine. |
| Mule accounts, ss 424A to 424C (added 2024) | Possessing or controlling another person's bank account or payment instrument without lawful authority, letting others control your account, or using accounts for unlawful transactions. | Fines and imprisonment, increasing with the seriousness of the conduct. |
| Criminal intimidation (ugutan jenayah), ss 503 and 506 | Threatening injury to a person, their reputation or property, to cause alarm or to make them do or not do something. | Up to 2 years, or fine, or both. If the threat is to cause death or grievous hurt (and some other serious cases), up to 7 years, or fine, or both. |
| Insulting modesty (mengaibkan kehormatan), s 509 | Words, sounds, gestures or objects intended to insult the modesty of a person, or intruding on their privacy. | Up to 5 years, or fine, or both. |
| Stalking (menghendap), s 507A | A course of conduct (such as following, contacting, watching or monitoring, online or offline) intended or known to be likely to cause distress, fear or alarm for a person's safety. | Up to 3 years, or fine, or both. In force from 31 May 2023; victims can also seek protection orders. |
| Bullying and harassment, ss 507B to 507G | Threatening, abusive or insulting words or conduct, including online, causing harassment, distress, fear or alarm; disclosing a person's identity information to harass (doxxing). | Various; in force from 11 July 2025. |
| Murder (membunuh), ss 300 and 302 | Culpable homicide with the intention or knowledge described in s 300. | Death, or imprisonment of 30 to 40 years; if not sentenced to death, also whipping of not less than 12 strokes (women and men over 50 are not whipped). |
Maximum penalties are not typical sentences. Courts consider the facts, the harm, any previous convictions and mitigation. First offenders who plead guilty to minor offences often receive fines or bonds. See The criminal process.
Recent amendments
- Abolition of the mandatory death penalty (in force 4 July 2023): the Abolition of Mandatory Death Penalty Act 2023 removed the mandatory death sentence for murder and other offences, giving judges a choice between death and imprisonment of 30 to 40 years (with whipping in many cases). It also replaced imprisonment "for natural life" with fixed terms. A separate 2023 Act let the Federal Court review the sentences of people already on death row.
- Stalking (in force 31 May 2023): s 507A, through the Penal Code (Amendment) Act 2023, with protection orders under the Criminal Procedure Code.
- Mule accounts (in force October 2024): ss 424A to 424D.
- Bullying, harassment and doxxing (in force 11 July 2025): ss 507B to 507G, through the Penal Code (Amendment) Act 2025.
- Attempted suicide decriminalised (in force 10 September 2025): the Penal Code (Amendment) (No. 2) Act 2023 repealed s 309, together with amendments to the Criminal Procedure Code and the Mental Health Act 2001 that focus on care and assessment instead of punishment. Abetment of suicide remains an offence.
Laws cited on this page
| Act 56 | Evidence Act 1950 · Akta Keterangan 1950 | Official text |
| Act 234 | Dangerous Drugs Act 1952 · Akta Dadah Berbahaya 1952 | Official text |
| Act 333 | Road Transport Act 1987 · Akta Pengangkutan Jalan 1987 | Official text |
| Act 521 | Domestic Violence Act 1994 · Akta Keganasan Rumah Tangga 1994 | Official text |
| Act 559 | Syariah Criminal Offences (Federal Territories) Act 1997 · Akta Kesalahan Jenayah Syariah (Wilayah-Wilayah Persekutuan) 1997 | Official text |
| Act 574 | Penal Code · Kanun Keseksaan | Official text |
| Act 588 | Communications and Multimedia Act 1998 · Akta Komunikasi dan Multimedia 1998 | Official text |
| Act 593 | Criminal Procedure Code · Kanun Tatacara Jenayah | Official text |
| Act 611 | Child Act 2001 · Akta Kanak-Kanak 2001 | Official text |
| Act 615 | Mental Health Act 2001 · Akta Kesihatan Mental 2001 | Official text |
| Act 846 | Abolition of Mandatory Death Penalty Act 2023 · Akta Pemansuhan Hukuman Mati Mandatori 2023 | Official text |
Listed automatically from the federal Acts named on this page. All laws of Malaysia →
Key sections
| Provision | What it says, in plain words |
|---|---|
| ss 76 to 106 | General exceptions: mistake of fact, accident, children, unsound mind, intoxication, consent, duress, private defence. |
| ss 82 and 83 | No offence by a child under 10; or by a child of 10 to under 12 without sufficient maturity of understanding. |
| ss 96 to 106 | Right of private defence of body and property, and its limits. |
| s 34 | Acts done by several persons in furtherance of a common intention: each is liable as if he did it alone. |
| s 302 | Murder: death, or 30 to 40 years' imprisonment (and whipping if not sentenced to death). |
| s 323 | Voluntarily causing hurt: up to 1 year, or fine up to RM2,000, or both. |
| s 379 | Theft: up to 7 years, or fine, or both. |
| s 406 | Criminal breach of trust: up to 10 years, whipping and fine. |
| s 409 | CBT by public servant, banker, agent etc.: 2 to 20 years, whipping, and liable to fine. |
| s 420 | Cheating and dishonestly inducing delivery of property: 1 to 10 years, whipping and fine. |
| ss 424A to 424C | Mule account offences (2024). |
| s 506 | Criminal intimidation: up to 2 years; up to 7 years for threats of death or grievous hurt. |
| s 507A | Stalking: up to 3 years, fine, or both (since 31 May 2023). |
| s 509 | Word or gesture intended to insult the modesty of a person: up to 5 years, fine, or both. |
| s 511 | Attempting an offence: generally up to half the longest prison term for the offence. |
Worked examples
Facts. Aminah pays RM2,500 to an online seller for a phone. The seller stops replying and the listing disappears. Other buyers report the same.
The law. If the seller deceived buyers into paying with no intention of delivering, that is cheating under s 415, punishable under s 420 with 1 to 10 years, whipping and a fine. If the money went through someone else's bank account, the account holder may face mule account offences (ss 424A to 424C).
Outcome. Aminah should make a police report quickly, call the National Scam Response Centre (997) if the payment was recent, and keep all chats and transfer receipts. The criminal case punishes the offender; she may also need a civil claim (for example small claims) to recover the money.
Facts. Mr Tan, treasurer of a residents' association, transfers RM30,000 of association funds to his own account to pay personal debts.
The law. The funds were entrusted to him. Dishonestly misappropriating them is criminal breach of trust (s 405), punishable under s 406 with imprisonment up to 10 years, whipping and a fine.
Outcome. The committee should make a police report and preserve bank records and minutes. Repaying the money later does not erase the offence, though it may be relevant to sentence.
Facts. After Siti ends a relationship, her ex-boyfriend messages her dozens of times a day from new accounts and waits outside her office.
The law. This course of conduct may be stalking under s 507A (up to 3 years, fine, or both), in force since 31 May 2023. If he threatens to harm her, criminal intimidation under s 506 may also apply.
Outcome. Siti should keep a log and screenshots, make a police report and ask about a protection order. If they were married, the Domestic Violence Act 1994 may also apply.
Facts. Ravi wakes to find an armed intruder in his house who lunges at him with a knife. Ravi strikes him with a chair, injuring him.
The law. Private defence of the body (ss 96 to 100) allows force to repel an attack that causes reasonable fear of death or grievous hurt, as long as it is not more than necessary (s 99). Ravi bears the burden of proving the exception if charged (Evidence Act s 105).
Outcome. Ravi's response is likely to be protected. He should make a police report immediately and give an accurate account. Force used after the danger has ended is not protected.
Examples are simplified illustrations with invented names; real cases turn on their own facts.
Questions & answers
What is the difference between cheating and criminal breach of trust?
In cheating (s 415), the offender deceives you into handing over property in the first place. In criminal breach of trust (s 405), you entrusted property to the person lawfully, and they later dishonestly misused it. Both carry imprisonment, whipping and a fine (ss 420 and 406).
Can a child be charged with a crime?
A child under 10 cannot commit an offence (s 82). A child aged 10 to under 12 is not liable if they lacked sufficient maturity to understand the act (s 83). Older children can be charged, but are dealt with in the Court for Children under the Child Act 2001.
Is stalking a crime in Malaysia?
Yes, since 31 May 2023. Section 507A makes stalking punishable with up to 3 years' imprisonment, a fine, or both. It covers online and offline conduct such as repeated unwanted contact, following and monitoring. Victims can also apply for protection orders.
Is the death penalty still in force?
Yes, but it is no longer mandatory. Since 4 July 2023, for murder and other offences that used to carry a mandatory death sentence, the court can choose between death and imprisonment of 30 to 40 years, usually with whipping. People already on death row could apply for review of their sentences.
Is attempted suicide still an offence?
No. Section 309 was repealed with effect from 10 September 2025. People in crisis are now directed to care and assessment. Helping or encouraging someone to take their own life is still a crime. If you or someone you know is in distress, contact emergency services or a crisis helpline.
Can I be jailed for letting a friend use my bank account?
Yes. Since October 2024, ss 424A to 424C make it an offence to allow others to control your account or payment instrument without lawful authority, to control someone else's, or to use accounts for unlawful transactions. Never lend, sell or rent your bank account or ATM card.
How much force can I use to protect myself?
Only what is necessary to defend against the threat (s 99). You may cause death only in the serious situations listed in s 100 (for example reasonable fear of death, grievous hurt, rape or kidnapping) or, for property, s 103. Once the danger is over, the right of private defence ends.
All questions & answers → · Ask your own →
Sources
- Laws of Malaysia portal: Penal Code (Act 574)
- WAO: Malaysia's anti-stalking law now operational (31 May 2023)
- Malay Mail: Dewan Rakyat passes Penal Code amendment to criminalise stalking (2023)
- The Vibes: Anti-bullying law takes effect (11 July 2025)
- The Vibes: Legal amendments decriminalising suicide now in effect (2025)
- Low & Partners: Keldai (mule) accounts, Penal Code (Amendment) Act 2024
- NST: Abolition of Mandatory Death Penalty Act 2023 in force 4 July 2023
- Malay Mail (Sept 2026): s 420 carries 1 to 10 years, whipping and fine
- Malay Mail (2022): s 406 carries up to 10 years, whipping and fine
- Daily Express (2026): s 506 death threat carries up to 7 years
Related
Criminal Procedure CodeThe criminal process: from police report to verdictYour rights when arrestedEvidence Act 1950Domestic Violence Act 1994Child Act 2001Communications and Multimedia Act 1998Courts and their powersSyariah Criminal Offences (Federal Territories) Act 1997 (Act 559)