• Skip to primary navigation
  • Skip to content
  • Skip to primary sidebar
  • Skip to footer
EDUCBA

EDUCBA

MENUMENU
  • Resources
        • Excel Charts

          • Histogram Chart Excel
          • Basic Excel Formulas
          • Text to Columns in Excel
        • Excel Charts
        • Excel Tips

          • Excel Gantt Chart
          • IFERROR with VLOOKUP
          • Data Table in Excel
        • Excel Tips
        • Excel Tools in Excel

          • Stacked Column Chart
          • Cheat Sheet of Excel Formulas
          • Excel Data Validation
        • Histogram chart in excel
        • Others

          • Resources (A-Z)
          • Excel Functions
          • Financial Functions in Excel
          • Logical Functions in Excel
          • Lookup Reference Functions in Excel
          • Maths Function in Excel
          • TEXT and String Functions in Excel
          • View All
  • Free Courses
  • All Courses
        • Certification Courses

          Excel Course 1
        • All in One Bundle

          All-in-One-Excel-VBA-Bundle
        • Excel course

          Excel-Training
        • Others

          • Excel advanced course
          • VBA Course
          • Excel Data Analysis Course
          • Excel for Marketing Course
          • Excel for Finance Course
          • View All
  • 120+ Courses All in One Bundle
  • Login

Excel REPT Function

Home » Excel » Blog » TEXT and String Functions in Excel » Excel REPT Function

REPT Function in Excel

REPT Function in Excel (Table of Contents)

  • REPT Function in Excel
  • REPT Formula in Excel
  • How to Use REPT Function in Excel?

REPT Function in Excel

If you want to fill a cell or pad values to a certain length. Or want to build histograms (a chart commonly used in financial modeling). These can be done by using REPT function by translating values directly into a certain number of characters.

Start Your Free Excel Course

Excel functions, formula, charts, formatting creating excel dashboard & others

What is REPT Function?

The REPT Function repeats characters a given or a specified number of times. This a built-in function in excel and falls under the Text/String function category.

It also can be used as a Worksheet function in excel. With this, the REPT function can be used as a part of a formula in a cell or worksheet.

REPT Formula in Excel

The Formula for the REPT Function in Excel is as follows:

REPT Formula in Excel

Where the supplied arguments are:

  • Text – The text you want to repeat.
  • Number_times – The number of times to repeat that text.

As REPT function is a built-in function in excel and categorized under Text/String functions category, thus it’s listed under FORMULAS tab. Please follow the below steps:

  • Click on FORMULAS tab.
  • Select Text functions category. It will open up a drop-down list.

REPT Function Step 1

  • Click on REPT function from the listed functions.

REPT Function Step 2

  • After clicking on REPT function, a Function arguments box will open up.

REPT Function Step 3

  • Pass the first argument of REPT function, which is text. The text which you want to repeat.
  • The second argument is Number_times, it specifies the number of times to repeat the text. It is a positive number.

How to use REPT function in excel?

REPT Function in Excel is very simple and easy to use. Let understand the working of REPT in Excel by Some Examples.

Popular Course in this category
Cyber Week Sale
Excel Advanced Training (14 Courses, 21+ Projects) 14 Online Courses | 21 Hands-on Projects | 129+ Hours | Verifiable Certificate of Completion | Lifetime Access
4.8 (2,613 ratings)
Course Price

View Course

Related Courses
Excel Data Analysis Training (12 Courses, 6+ Projects)
You can download this REPT Function Excel Template here – REPT Function Excel Template

Example #1

We have given below data:

REPT Example 1

Now we will apply the REPT function on the above data:

REPT Example 1-1

As per the above screenshot, the REPT function will repeat the character “_“ hyphen 5 times.

REPT Example 1-2

Now drag & drop this function for the below values.

REPT Example 1-3

The final result is:

REPT Example 1-4

Example #2

We also can apply the REPT function on a string as well.

REPT Example 2

We will apply the REPT function here

REPT Example 2-1

The results are:

REPT Example 2-2

Now drag & drop this function for the below values.

REPT Example 2-3

Example #3

To create a simple in-cell chart or column chart, we will use the REPT function. Here we will use a percentage data to create the cell chart.

REPT Example 3

Steps are as follows:

  • Increase the size/height of row where you want to insert the chart so that the column bar will adjust in it.

REPT Example 3-1

  • Insert the REPT function formula in the cell A30 and enter.

REPT Example 3-2

The result is:

REPT Example 3-3

  • Now, change the orientation of text to “Rotate Text Up” as per below screenshot.

REPT Example 3-4

  • Change the font style to PLAYBILL and alignment to bottom & center.

REPT Example 3-5

  • Apply the same steps for the rest values.
  • Finally, you will get the In-cell column chart.

REPT Example 3-6

With the same steps, you can also create an In cell bar chart too.

Example #4

We have given the financial data and it is needed to make all the numbers of the same length. For this, we will add Zero in the numbers in such a way so that the value of the number doesn’t change.

REPT Example 4

We want all the numbers should be of length 5. For this, we will use the REPT function:

REPT Example 4-1

The result is:

REPT Example 4-2

Drag & drop the above function for the rest values and the final results are:

REPT Example 4-3

Explanation:

  • We will first take the length of the string.
  • Then subtract the length from 5 (mentioned length which we want to make for all numbers).
  • REPT function will return the number of 0’s based on the number, which is occurring after subtracting from the number 5.

For example, If the number is 91, it would return 000.

Things to Remember About REPT Function in Excel

  • If the second argument number_times is Zero, then the function returns an empty string.
  • If number_times is a decimal value, it will truncate to an integer. For example, if the values are 5.93, it will only consider 5.
  • The result of the REPT function must be no longer than 32,767 characters. Otherwise, it will return #VALUE! error.

Recommended Articles

This has been a guide to REPT in Excel. Here we discuss the REPT Formula in Excel and how to use REPT Function in Excel along with excel example and downloadable excel templates. You may also look at these useful functions in excel –

  1. Use of IRR Function in Excel
  2. RIGHT Function Excel
  3. How to Use Excel LEN Function
  4. HLOOKUP Function in Excel

All in One Excel VBA Bundle (120+ Courses, 30+ Projects)

120+ Online Courses

30+ Projects

500+ Hours

Verifiable Certificates

Lifetime Access

Learn More

2 Shares
Share
Tweet
Share
Reader Interactions
Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Primary Sidebar
Excel Functions Tutorials
  • TEXT and String Functions in Excel
    • Excel Find
    • TRIM Formula in Excel
    • LEFT Formula in Excel
    • Opposite of Concatenate in Excel
    • Concatenate Strings in Excel
    • Extract Numbers From String
    • VALUE Formula in Excel
    • Left TRIM in Excel
    • Substring Excel Function
    • SUBSTITUTE Function in Excel
    • Excel VALUE Function
    • Excel REPT Function
    • Excel TRIM Function
    • Excel CHAR Function
    • Excel CLEAN Function
    • Excel EXACT Function
    • PROPER Function in Excel
    • Excel LEFT Function
    • MID Function in Excel
    • LEN Function in Excel
    • CONCATENATE Function in Excel
    • SEARCH Function in Excel
    • RIGHT Function in Excel
    • FIND Function in Excel
    • TEXT Function in Excel
  • Excel Functions (10+)
  • Excel Tools (97+)
  • Financial Functions in Excel (17+)
  • Logical Functions in Excel (12+)
  • Lookup Reference Functions in Excel (30+)
  • Maths Function in Excel (39+)
  • Date and Time Function in Excel (20+)
  • Statistical Functions in Excel (55+)
  • Information Functions in Excel (4+)
  • Excel Charts (44+)
  • Excel Tips (195+)
  • VBA (180+)
  • Workplace Productivity (4+)
  • Microsoft Office Tools (14+)
  • Excel Formula and Functions (20+)
  • MS Excel Shortcuts (4+)
Excel Functions Courses
  • EXCEL ADVANCED Online COURSE
  • Online Excel Data Analysis Training
Footer
About Us
  • Who is EDUCBA?
  • Sign Up
  •  
Free Courses
  • Free Online Excel Course
  • Free Vba Course
Certification Courses
  • All Courses
  • Excel VBA Course - All in One Bundle
  • VBA Course
  • Excel Data Analysis Course
  • Excel for Marketing Course
  • Excel for Finance Course
  • Excel for HR Training
Resources
  • Resources (A To Z)
  • Excel Charts
  • Excel Tips
  • Excel Tools in Excel
  • Excel Functions
  • Financial Functions in Excel
  • Logical Functions in Excel
  • Lookup Reference Functions in Excel
  • Maths Function in Excel
  • TEXT and String Functions in Excel
  • Date and Time Function in Excel
  • Statistical Functions in Excel
  • Information Functions in Excel
Apps
  • iPhone & iPad
  • Android
Support
  • Contact Us
  • Verifiable Certificate
  • Reviews
  • Terms and Conditions

© 2019 - EDUCBA. ALL RIGHTS RESERVED. THE CERTIFICATION NAMES ARE THE TRADEMARKS OF THEIR RESPECTIVE OWNERS.

EDUCBA

Download REPT Function Excel Template

By continuing above step, you agree to our Terms of Use and Privacy Policy.
EDUCBA
Free Excel Course

Excel functions, formula, charts, formatting creating excel dashboard & others

By continuing above step, you agree to our Terms of Use and Privacy Policy.
*Please provide your correct email id. Login details for this Free course will be emailed to you
EDUCBA
Free Excel Course

Excel functions, formula, charts, formatting creating excel dashboard & others

By continuing above step, you agree to our Terms of Use and Privacy Policy.
*Please provide your correct email id. Login details for this Free course will be emailed to you
EDUCBA
Free Excel Course

Excel functions, formula, charts, formatting creating excel dashboard & others

By continuing above step, you agree to our Terms of Use and Privacy Policy.
*Please provide your correct email id. Login details for this Free course will be emailed to you
EDUCBA
Free Excel Course

Excel functions, formula, charts, formatting creating excel dashboard & others

By continuing above step, you agree to our Terms of Use and Privacy Policy.
*Please provide your correct email id. Login details for this Free course will be emailed to you
EDUCBA

By continuing above step, you agree to our Terms of Use and Privacy Policy.
*Please provide your correct email id. Login details for this Free course will be emailed to you
EDUCBA Login

Forgot Password?

Let’s Get Started
Please provide your Email ID
Email ID is incorrect

Cyber Week Offer - All in One Excel VBA Bundle (120+ Courses, 500+ hours of Videos) View More

Cyber Week Offer - Cyber Week Offer - All in One Excel VBA Bundle (120+ Courses, 500+ hours of Videos) View More