Enter your birth year to discover your Chinese Zodiac animal and learn about its characteristics.
Understanding the Chinese Zodiac
The Chinese Zodiac, known as Sheng Xiao (生肖), is a repeating cycle of 12 years, with each year represented by an animal and its reputed attributes. Originating from ancient Chinese astronomy and astrology, it is still widely used today in many East Asian countries to determine personality traits, compatibility, and even fortune.
The 12 Zodiac Animals
The 12 animals of the Chinese Zodiac, in their traditional order, are:
Your Chinese Zodiac sign is determined by the year of your birth. Each animal rules for one year, and the cycle repeats every 12 years. For instance, if you were born in a Rat year, then every 12 years after that will also be a Rat year. While the exact start date of the Chinese New Year (which marks the change of the Zodiac animal) varies each year based on the lunar calendar, this calculator uses the Gregorian calendar year for simplicity, which is common for general zodiac sign determination.
Examples:
If you were born in 1984, your sign is the Rat.
If you were born in 1990, your sign is the Horse.
If you were born in 2000, your sign is the Dragon.
If you were born in 2023, your sign is the Rabbit.
Discover your sign and explore the fascinating world of the Chinese Zodiac!
.chinese-sign-calculator {
font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
background-color: #f9f9f9;
padding: 25px;
border-radius: 10px;
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
max-width: 700px;
margin: 20px auto;
color: #333;
}
.chinese-sign-calculator h2 {
color: #8B0000; /* Dark Red */
text-align: center;
margin-bottom: 20px;
font-size: 2em;
}
.chinese-sign-calculator p {
line-height: 1.6;
margin-bottom: 10px;
}
.calculator-inputs {
display: flex;
flex-direction: column;
gap: 15px;
margin-bottom: 25px;
align-items: center;
}
.calculator-inputs label {
font-weight: bold;
color: #555;
font-size: 1.1em;
}
.calculator-inputs input[type="number"] {
padding: 12px 15px;
border: 1px solid #ccc;
border-radius: 6px;
font-size: 1em;
width: 100%;
max-width: 200px;
box-sizing: border-box;
}
.calculator-inputs button {
background-color: #8B0000; /* Dark Red */
color: white;
padding: 12px 25px;
border: none;
border-radius: 6px;
cursor: pointer;
font-size: 1.1em;
transition: background-color 0.3s ease;
}
.calculator-inputs button:hover {
background-color: #A52A2A; /* Brownish Red */
}
.calculator-result {
background-color: #fff;
border: 1px solid #ddd;
padding: 20px;
border-radius: 8px;
min-height: 60px;
display: flex;
align-items: center;
justify-content: center;
font-size: 1.3em;
font-weight: bold;
color: #8B0000; /* Dark Red */
text-align: center;
margin-top: 20px;
}
.calculator-article {
margin-top: 30px;
border-top: 1px solid #eee;
padding-top: 20px;
}
.calculator-article h3, .calculator-article h4 {
color: #8B0000; /* Dark Red */
margin-top: 20px;
margin-bottom: 15px;
font-size: 1.5em;
}
.calculator-article ol, .calculator-article ul {
margin-left: 25px;
margin-bottom: 15px;
}
.calculator-article li {
margin-bottom: 8px;
line-height: 1.5;
}
.calculator-article strong {
color: #555;
}
function calculateChineseSign() {
var birthYearInput = document.getElementById("birthYear");
var resultDiv = document.getElementById("result");
var birthYear = parseInt(birthYearInput.value);
if (isNaN(birthYear) || birthYear 3000) { // Reasonable year range
resultDiv.innerHTML = "Please enter a valid birth year.";
return;
}
var animals = ["Rat", "Ox", "Tiger", "Rabbit", "Dragon", "Snake", "Horse", "Goat", "Monkey", "Rooster", "Dog", "Pig"];
// The cycle starts with Rat in 1984, 1972, 1960, etc.
// (year – 4) % 12 gives 0 for Rat years (e.g., 1984-4 = 1980, 1980%12 = 0)
var index = (birthYear – 4) % 12;
// Adjust for negative results if year is very early (e.g., before 4 AD)
if (index < 0) {
index += 12;
}
var chineseSign = animals[index];
resultDiv.innerHTML = "Your Chinese Zodiac sign is the: " + chineseSign + "!";
}
// Set a default value and calculate on page load for initial display
document.addEventListener('DOMContentLoaded', function() {
document.getElementById('birthYear').value = new Date().getFullYear() – 30; // Default to 30 years ago
calculateChineseSign();
});