datetime module in python show only date and time code example Example: python datetime date only # Use the date() method: datetime.datetime.now().date()