---
title: "How to create a Date object in JavaScript?"  
description: "How to create a Date object in JavaScript?"  
author: "Amit Singh"  
published: 2011-04-23  
updated: 2020-09-18  
canonical: https://www.mindstick.com/interview/767/how-to-create-a-date-object-in-javascript  
category: "javascript"  
tags: ["javascript"]  
reading_time: 1 minute  

---

# How to create a Date object in JavaScript?

We create a data object in javascript as:

## dateObjectName = new Date([parameters])

## Answers

### Answer by Amit Singh

We create a data object in javascript as:

## dateObjectName = new Date([parameters])

### Answer by Amit Singh

## Create a direct instance of an object forexample:

**dateObjectName = new Date([parameters])**

The syntax for accessing a property of an object is:

dateObjectName.propertyname


---

Original Source: https://www.mindstick.com/interview/767/how-to-create-a-date-object-in-javascript

Copyright © MindStick Software Pvt. Ltd. This Markdown version is provided for developers, AI systems, and offline reading.
