
- Trending Categories
Data Structure
Networking
RDBMS
Operating System
Java
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
How to Create a Checkmark / Tick with CSS
We can create a customized checkmark using CSS. The following examples illustrate this effect −
Example
<!DOCTYPE html> <html> <style> div { margin: 2%; position: relative; width: 40px; height: 40px; box-shadow: inset 0 0 12px lightblue; } div::before { content: ""; position: absolute; width: 8px; top: 50%; height: 50%; border-radius: 2px; background-color: rgb(123,45,20); transform: translateX(12px) rotate(-45deg); transform-origin: left bottom; z-index: +1; } div::after { content: ""; position: absolute; bottom: 0; height: 8px; width: 100%; border-radius: 2px; background-color: rgb(200,52,120); transform: translateX(12px) rotate(-45deg); transform-origin: left bottom; } </style> <body> Custom mark! <div></div> </body> </html>
Output
This will produce the following result −
Example
<!DOCTYPE html> <html> <style> body { padding: 2%; text-align: center; } div { display: inline-block; height: 100px; width: 35px; border-bottom: 10px solid chartreuse; border-right: 10px solid chartreuse; transform: rotate(45deg); } </style> <body> <div></div> </body> </html>
Output
This will produce the following result −
- Related Questions & Answers
- How to create a pagination with CSS?
- How to create a Calendar with CSS?
- How to create a preloader with CSS?
- How to create a transition effect with CSS?
- How to create a Hero Image with CSS?
- How to create a responsive image with CSS?
- How to create a vertical menu with CSS?
- How to create a subnavigation menu with CSS?
- How to create a Menu Icon with CSS?
- How to create a Hoverable Sidenav with CSS?
- How to create a dropup menu with CSS?
- How to create a breadcrumb navigation with CSS?
- How to create a responsive header with CSS?
- How to create a sticky image with CSS?
- How to create a contact form with CSS?
Advertisements