{"id":8674,"date":"2021-04-02T11:30:00","date_gmt":"2021-04-02T09:30:00","guid":{"rendered":"https:\/\/blog.sheetgo.com\/?p=8674"},"modified":"2021-04-02T11:30:00","modified_gmt":"2021-04-02T09:30:00","slug":"timevalue-formula-in-google-sheets","status":"publish","type":"post","link":"https:\/\/www.sheetgo.com\/es\/blog\/google-sheets-formulas\/timevalue-formula-in-google-sheets\/","title":{"rendered":"C\u00f3mo utilizar la f\u00f3rmula TIMEVALUE de Google Sheets"},"content":{"rendered":"<p>[et_pb_section fb_built=&#8221;1&#8243; admin_label=&#8221;section&#8221; module_class=&#8221;sheetgo-post&#8221; _builder_version=&#8221;4.16&#8243; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;][et_pb_row admin_label=&#8221;row&#8221; _builder_version=&#8221;4.16&#8243; background_size=&#8221;initial&#8221; background_position=&#8221;top_left&#8221; background_repeat=&#8221;repeat&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;][et_pb_column type=&#8221;4_4&#8243; _builder_version=&#8221;4.16&#8243; custom_padding=&#8221;|||&#8221; global_colors_info=&#8221;{}&#8221; custom_padding__hover=&#8221;|||&#8221; theme_builder_area=&#8221;post_content&#8221;][et_pb_text _builder_version=&#8221;4.16&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;]<\/p>\n<p>When dealing with data in spreadsheets, having dates and times in string format is commonplace. While they convey the time, they may not be ideal for any kind of calculations or data processing. A way to get around that is to convert them into numerical time format. That is purpose of the <a href=\"https:\/\/support.google.com\/docs\/answer\/3267350\" target=\"_blank\" rel=\"noopener noreferrer\">TIMEVALUE<\/a> formula in Google Sheets.<\/p>\n<p>[\/et_pb_text][et_pb_text _builder_version=&#8221;4.16&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;]<\/p>\n<h3>Syntax<\/h3>\n<p>[\/et_pb_text][et_pb_text module_class=&#8221;spreadsheet-function&#8221; _builder_version=&#8221;4.16&#8243; border_width_left=&#8221;4px&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;]=TIMEVALUE(time_string)[\/et_pb_text][et_pb_text _builder_version=&#8221;4.16&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;]<\/p>\n<ul>\n<li><b>time_string<\/b> \u2013 is the text string that represents time in either 12-hour or 24-hour time format. Like any other formulas that take in string parameters, you should enclose the time string in double quotes. You can also use a reference to the cell that holds the time string.<\/li>\n<\/ul>\n<p>[\/et_pb_text][\/et_pb_column][\/et_pb_row][et_pb_row _builder_version=&#8221;4.27.2&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;][et_pb_column type=&#8221;4_4&#8243; _builder_version=&#8221;4.27.2&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;][et_pb_text admin_label=&#8221;Connections T &#8211; Automate beyond importrange &#8211; Horizontal&#8221; module_class=&#8221;sheetgo-post-no-shadow-img md2-contained-button-light vertical-banner-container&#8221; _builder_version=&#8221;4.27.2&#8243; _module_preset=&#8221;default&#8221; background_color=&#8221;#f2f7ff&#8221; max_width=&#8221;700px&#8221; module_alignment=&#8221;center&#8221; max_height=&#8221;300px&#8221; custom_margin=&#8221;20px|0px|20px|0px|true|true&#8221; custom_padding=&#8221;25px|25px|25px|25px|true|true&#8221; sticky_limit_bottom=&#8221;section&#8221; border_radii=&#8221;on|20px|20px|20px|20px&#8221; border_width_all=&#8221;1px&#8221; border_color_all=&#8221;#d9e7ff&#8221; saved_tabs=&#8221;all&#8221; global_colors_info=&#8221;{}&#8221; global_module=&#8221;50462&#8243; theme_builder_area=&#8221;post_content&#8221;]<img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/static.sheetgo.com\/wp-content\/uploads\/2024\/09\/Add-on-sm_sheets-connected-new-connection.webp\" width=\"250\" height=\"168\" alt=\"\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/static.sheetgo.com\/wp-content\/uploads\/2024\/09\/Recommended-for-Google-Workspace-badge.webp\" width=\"150\" height=\"180\" alt=\"39\" \/><\/p>\n<p><span style=\"font-size: 22px; font-weight: 600;\">Automate data transfers beyond Importrange<\/span><\/p>\n<p><a href=\"https:\/\/www.sheetgo.com\/connections\/\" target=\"_blank\" rel=\"noopener\">Find out how<\/a>[\/et_pb_text][\/et_pb_column][\/et_pb_row][et_pb_row admin_label=&#8221;row&#8221; _builder_version=&#8221;4.16&#8243; background_size=&#8221;initial&#8221; background_position=&#8221;top_left&#8221; background_repeat=&#8221;repeat&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;][et_pb_column type=&#8221;4_4&#8243; _builder_version=&#8221;4.16&#8243; custom_padding=&#8221;|||&#8221; global_colors_info=&#8221;{}&#8221; custom_padding__hover=&#8221;|||&#8221; theme_builder_area=&#8221;post_content&#8221;][et_pb_text _builder_version=&#8221;4.16&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;]<\/p>\n<h3>Usage: Google Sheets TIMEVALUE<\/h3>\n<p>The TIMEVALUE function essentially converts a time string into a number format by expressing it as a fraction of a day. This fraction is in decimal terms, so for instance, 12:00 noon would be 0.5, since it\u2019s halfway through the 24 hour day. The output of the TIMEVALUE function is therefore a number between 0 and 1.<\/p>\n<p>To illustrate this further, see the example below. I have the time string of 6 pm, and I\u2019m converting it to number format.<\/p>\n<p>[\/et_pb_text][et_pb_image src=&#8221;https:\/\/static.sheetgo.com\/wp-content\/uploads\/2021\/10\/Google-Sheets-TIMEVALUE-1.png&#8221; alt=&#8221;Google Sheets TIMEVALUE 1&#8243; title_text=&#8221;Google Sheets TIMEVALUE 1&#8243; _builder_version=&#8221;4.16&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;][\/et_pb_image][et_pb_text _builder_version=&#8221;4.16&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;]<\/p>\n<p>In the first example here, I get the decimal value that I mentioned above. Because 6pm is \u00be of the way through a day, it is expressed in decimal form as 0.75. In the second example, I use the exact same formula but change the format of the cell using the Google Sheets toolbar. This changes the format from decimal form into a typical time form. The underlying number is still 0.75, but it\u2019s expressed as 18:00:00, which is a bit easier on the eyes!<\/p>\n<p>I\u2019ll show a few more examples below. The first three examples accepted direct time strings (by typing them into the formula with quotation marks) and accordingly converted them into time values. The last two examples demonstrate the TIMEVALUE formula\u2019s capability to accept cell references that have the time or date-time text strings. The time strings can be any of the following:<\/p>\n<p>[\/et_pb_text][et_pb_text _builder_version=&#8221;4.16&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;]<\/p>\n<ul>\n<li>hh AM\/PM (12-hour format)<\/li>\n<li>hh:mm:ss (24-hour format)<\/li>\n<li>hh:mm:ss AM\/PM (12-hour format)<\/li>\n<li>hh:mm (24-hour format)<\/li>\n<li>hh:mm AM\/PM (12-hour format)<\/li>\n<\/ul>\n<p>[\/et_pb_text][et_pb_image src=&#8221;https:\/\/static.sheetgo.com\/wp-content\/uploads\/2021\/04\/2.-TIMEVALUE-example-2.png&#8221; alt=&#8221;google sheets timevalue 2&#8243; title_text=&#8221;2. TIMEVALUE example 2&#8243; align=&#8221;center&#8221; _builder_version=&#8221;4.23.1&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;][\/et_pb_image][et_pb_text _builder_version=&#8221;4.16&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;]<\/p>\n<p>There\u2019s another interesting thing to note in the final example: the TIMEVALUE function can accept times with dates in the same cell. It simply ignores the date, and extracts the time. That can be extremely useful if you want to separate dates and times in your spreadsheet!<\/p>\n<p>The TIMEVALUE function is also very precise. Looking at the last example, you can see how precise the decimal number is. You can also enter times down to a fraction of a second \u2013 in the example in row 4, I specify the seconds as 46.8 seconds!<\/p>\n<p>You can leave the output of the TIMEVALUE function in number format, or convert it to any one of the available time formats in Google Sheets to suit your preference.<\/p>\n<p>[\/et_pb_text][et_pb_text _builder_version=&#8221;4.22.2&#8243; background_color=&#8221;#f9f9ff&#8221; custom_margin=&#8221;40px||40px||false|false&#8221; custom_padding=&#8221;15px|25px|15px|25px|true|true&#8221; border_width_left=&#8221;3px&#8221; border_color_left=&#8221;#808e95&#8243; global_module=&#8221;26540&#8243; saved_tabs=&#8221;all&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;]<\/p>\n<p><em><strong>Editor\u2019s note<\/strong>: This is a revised version of a previous post that has been updated for accuracy and comprehensiveness.<\/em><\/p>\n<p>[\/et_pb_text][\/et_pb_column][\/et_pb_row][et_pb_row _builder_version=&#8221;4.27.2&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;][et_pb_column type=&#8221;4_4&#8243; _builder_version=&#8221;4.27.2&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;][et_pb_text admin_label=&#8221;Connections T &#8211; One tool &#8211; Horizontal&#8221; module_class=&#8221;sheetgo-post-no-shadow-img md2-contained-button vertical-banner-container&#8221; _builder_version=&#8221;4.27.2&#8243; _module_preset=&#8221;default&#8221; background_color=&#8221;#f2f7ff&#8221; max_width=&#8221;700px&#8221; module_alignment=&#8221;center&#8221; max_height=&#8221;300px&#8221; custom_margin=&#8221;20px|0px|20px|0px|true|true&#8221; custom_padding=&#8221;25px|25px|25px|25px|true|true&#8221; sticky_limit_bottom=&#8221;section&#8221; border_radii=&#8221;on|20px|20px|20px|20px&#8221; border_width_all=&#8221;1px&#8221; border_color_all=&#8221;#d9e7ff&#8221; global_colors_info=&#8221;{}&#8221; global_module=&#8221;50458&#8243; theme_builder_area=&#8221;post_content&#8221;]<img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/static.sheetgo.com\/wp-content\/uploads\/2024\/09\/connections-top-processors-main.webp\" width=\"250\" height=\"168\" alt=\"\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/static.sheetgo.com\/wp-content\/uploads\/2024\/09\/Recommended-for-Google-Workspace-badge.webp\" width=\"150\" height=\"180\" alt=\"39\" \/><\/p>\n<p><span style=\"font-size: 22px; font-weight: 600;\">One tool to merge, split, and filter all your spreadsheet data<\/span><\/p>\n<p><a href=\"https:\/\/www.sheetgo.com\/connections\/\" target=\"_blank\" rel=\"noopener\">Find out how<\/a>[\/et_pb_text][\/et_pb_column][\/et_pb_row][\/et_pb_section]<\/p>\n","protected":false},"excerpt":{"rendered":"<p>When dealing with data in spreadsheets, having dates and times in string format is commonplace. While they convey the time, they may not be ideal for any kind of calculations or data processing. A way to get around that is to convert them into numerical time format. That is purpose of the TIMEVALUE formula in [&hellip;]<\/p>\n","protected":false},"author":40,"featured_media":33487,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"_et_pb_use_builder":"on","_et_pb_old_content":"While dealing with data in spreadsheets, getting to see the dates and times in string format is commonplace. While they convey the time, we can't use them directly for any kind of calculations or data processing. Unless we have a way to convert them into the time format. The purpose of the <a href=\"https:\/\/support.google.com\/docs\/answer\/3267350\" target=\"_blank\" rel=\"noopener noreferrer\">TIMEVALUE<\/a> formula in Google Sheets application is just that.\n<h3>Syntax<\/h3>\n<strong>TIMEVALUE(time_string)<\/strong>\n<ul>\n \t<li><strong>time_string<\/strong> - is the text string that represents time in either 12-hour or 24-hour time format. Like any other formulas that take in string parameters, we should enclose the time string in double quotes. And, we can also use the reference of the cell that holds the time string.<\/li>\n<\/ul>\n<h3>Usage: TIMEVALUE formula in Google Sheets<\/h3>\nCompared to other formulas in Google Sheets, this is certainly is one of the simplest and straightforward to use. However, it is always a good idea to approach the formula practically. Please consider the following snapshot.\n\n<img class=\"aligncenter size-full wp-image-8742\" src=\"https:\/\/static.sheetgo.com\/wp-content\/uploads\/2018\/06\/TIMEVALUE-formula-Illustration-Frame-1.png\" alt=\"TIMEVALUE formula in Google Sheets\" width=\"863\" height=\"524\">\n\nThe first three examples accepted direct time strings and accordingly converted them into time objects. The last two examples demonstrate the TIMEVALUE formula's capability to accept cell references that have the time&nbsp;or date-time text strings. The time strings can be any of the following:\n<ul>\n \t<li>hh AM\/PM (12-hour format)<\/li>\n \t<li>hh:mm:ss&nbsp;(24-hour format)<\/li>\n \t<li>hh:mm:ss&nbsp;AM\/PM (12-hour format)<\/li>\n \t<li>hh:mm&nbsp;(24-hour format)<\/li>\n \t<li>hh:mm AM\/PM (12-hour format)<\/li>\n<\/ul>\nPlease note that just like a date in Google Sheets is a natural number, a time is a decimal number between 0 to 1. The value 0 represents 12:00:00 AM. We illustrated this in the final example. Not only does it ignore the date component of the date-time string, it just converted the string \"13:29:32\" into a time value as shown in the cell B6.\n\nIt is interesting to note that the formula also considers milliseconds - we demonstrated this in the third example. We&nbsp;purposely left the final output in number format.&nbsp;That is to validate that the TIMEVALUE formula actually converts the time string into a numeric value.","_et_gb_content_width":"","footnotes":""},"categories":[54],"tags":[39,28],"class_list":["post-8674","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-google-sheets-formulas","tag-connections-t","tag-spreadsheets"],"acf":[],"_links":{"self":[{"href":"https:\/\/www.sheetgo.com\/es\/wp-json\/wp\/v2\/posts\/8674","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.sheetgo.com\/es\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.sheetgo.com\/es\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.sheetgo.com\/es\/wp-json\/wp\/v2\/users\/40"}],"replies":[{"embeddable":true,"href":"https:\/\/www.sheetgo.com\/es\/wp-json\/wp\/v2\/comments?post=8674"}],"version-history":[{"count":0,"href":"https:\/\/www.sheetgo.com\/es\/wp-json\/wp\/v2\/posts\/8674\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.sheetgo.com\/es\/wp-json\/wp\/v2\/media\/33487"}],"wp:attachment":[{"href":"https:\/\/www.sheetgo.com\/es\/wp-json\/wp\/v2\/media?parent=8674"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.sheetgo.com\/es\/wp-json\/wp\/v2\/categories?post=8674"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.sheetgo.com\/es\/wp-json\/wp\/v2\/tags?post=8674"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}