diff --git a/doc/man/nanorc.5 b/doc/man/nanorc.5
index 6fec53a675c009253a3cd86cf39ac8cb6e0bd38d..86978198833cffa4fa798879f39441681972bcd0 100644
--- a/doc/man/nanorc.5
+++ b/doc/man/nanorc.5
@@ -153,6 +153,10 @@ Don't automatically add a newline to the ends of files.
 .B set nowrap
 Don't hard-wrap text at all.
 .TP
+.B set numbercolor \fIfgcolor\fR,\fIbgcolor\fR
+Specify the color combination to use for line numbers.
+See \fBset titlecolor\fR for more details.
+.TP
 .B set operatingdir "\fIdirectory\fP"
 \fBnano\fP will only read and write files inside \fIdirectory\fP and its
 subdirectories.  Also, the current directory is changed to here, so
diff --git a/doc/syntax/nanorc.nanorc b/doc/syntax/nanorc.nanorc
index 8b911bb0f6212cd3ed84881de08ef981b4bd48ae..92d3319307c821aa00780cec19b48a6e4eeeae91 100644
--- a/doc/syntax/nanorc.nanorc
+++ b/doc/syntax/nanorc.nanorc
@@ -8,8 +8,8 @@ icolor brightred "^[[:space:]]*((un)?(bind|set)|include|syntax|header|comment|ma
 
 # Keywords
 icolor brightgreen "^[[:space:]]*(set|unset)[[:space:]]+(allow_insecure_backup|autoindent|backup|backwards|boldtext|casesensitive|constantshow|cut|fill|historylog|justifytrim|locking|morespace|mouse|multibuffer|noconvert|nohelp|nonewlines|nowrap|positionlog|preserve|quickblank|quiet|rebinddelete|rebindkeypad|regexp|showcursor|smarthome|smooth|softwrap|suspend|tabsize|tabstospaces|tempfile|unix|view|wordbounds)\>"
-icolor yellow "^[[:space:]]*set[[:space:]]+(functioncolor|keycolor|statuscolor|titlecolor)[[:space:]]+(bright)?(white|black|red|blue|green|yellow|magenta|cyan)?(,(white|black|red|blue|green|yellow|magenta|cyan))?\>"
-icolor brightgreen "^[[:space:]]*set[[:space:]]+(backupdir|brackets|functioncolor|keycolor|matchbrackets|operatingdir|punct|quotestr|speller|statuscolor|titlecolor|whitespace|wordchars)[[:space:]]+"
+icolor yellow "^[[:space:]]*set[[:space:]]+((function|key|number|status|title)color)[[:space:]]+(bright)?(white|black|red|blue|green|yellow|magenta|cyan)?(,(white|black|red|blue|green|yellow|magenta|cyan))?\>"
+icolor brightgreen "^[[:space:]]*set[[:space:]]+(backupdir|brackets|functioncolor|keycolor|matchbrackets|numbercolor|operatingdir|punct|quotestr|speller|statuscolor|titlecolor|whitespace|wordchars)[[:space:]]+"
 icolor brightgreen "^[[:space:]]*bind[[:space:]]+((\^([[:alpha:]]|[]0-9\^_]|Space)|M-([[:alpha:]]|[]!"#$%&'()*+,./0-9:;<=>?@\^_`{|}~-]|Space))|F([1-9]|1[0-6])|Ins|Del)[[:space:]]+[[:alpha:]]+[[:space:]]+(all|main|search|replace(with)?|gotoline|writeout|insert|ext(ernal)?cmd|help|spell|linter|browser|whereisfile|gotodir)([[:space:]]+#|[[:space:]]*$)"
 icolor brightgreen "^[[:space:]]*unbind[[:space:]]+((\^([[:alpha:]]|[]0-9\^_]|Space)|M-([[:alpha:]]|[]!"#$%&'()*+,./0-9:;<=>?@\^_`{|}~-]|Space))|F([1-9]|1[0-6])|Ins|Del)[[:space:]]+(all|main|search|replace(with)?|gotoline|writeout|insert|ext(ernal)?cmd|help|spell|linter|browser|whereisfile|gotodir)([[:space:]]+#|[[:space:]]*$)"
 icolor brightgreen "^[[:space:]]*extendsyntax[[:space:]]+[[:alpha:]]+[[:space:]]+(i?color|header|magic|comment|linter|formatter)[[:space:]]+.*$"
diff --git a/doc/texinfo/nano.texi b/doc/texinfo/nano.texi
index d4f64265186805e8d6bb1d1d626ad9993cdff984..2b5c8539816ba978d62df7fd6fe468ef8af3e5b0 100644
--- a/doc/texinfo/nano.texi
+++ b/doc/texinfo/nano.texi
@@ -731,6 +731,10 @@ Don't add newlines to the ends of files.
 @item set nowrap
 Don't hard-wrap text at all.
 
+@item set numbercolor @var{fgcolor},@var{bgcolor}
+Specify the color combination to use for line numbers.
+See @code{set titlecolor} for more details.
+
 @item set operatingdir "directory"
 @code{nano} will only read and write files inside "directory" and its
 subdirectories.  Also, the current directory is changed to here, so
diff --git a/src/nano.c b/src/nano.c
index d1ee039b9ff9558c3fdc7d4100a2a9caa798c918..a4f43c42d2e451e7a49f6c13044c12938662a672 100644
--- a/src/nano.c
+++ b/src/nano.c
@@ -2577,6 +2577,7 @@ int main(int argc, char **argv)
     set_colorpairs();
 #else
     interface_color_pair[TITLE_BAR] = hilite_attribute;
+    interface_color_pair[LINE_NUMBER] = hilite_attribute;
     interface_color_pair[STATUS_BAR] = hilite_attribute;
     interface_color_pair[KEY_COMBO] = hilite_attribute;
     interface_color_pair[FUNCTION_TAG] = A_NORMAL;
diff --git a/src/nano.h b/src/nano.h
index 4e1e35f8d06156056153fb9824bc5ffb5dd91dac..93ec5e1b708093914843410b8f91397c2e0c22ea 100644
--- a/src/nano.h
+++ b/src/nano.h
@@ -488,6 +488,7 @@ typedef struct subnfunc {
 enum
 {
     TITLE_BAR = 0,
+    LINE_NUMBER,
     STATUS_BAR,
     KEY_COMBO,
     FUNCTION_TAG,
diff --git a/src/rcfile.c b/src/rcfile.c
index 72a58808526b6df781693647502d39b37a65246d..a570952cb9b9aa709f3b6cd331a96c305394daf2 100644
--- a/src/rcfile.c
+++ b/src/rcfile.c
@@ -111,6 +111,7 @@ static const rcoption rcopts[] = {
 #endif
 #ifndef DISABLE_COLOR
     {"titlecolor", 0},
+    {"numbercolor", 0},
     {"statuscolor", 0},
     {"keycolor", 0},
     {"functioncolor", 0},
@@ -1121,6 +1122,8 @@ void parse_rcfile(FILE *rcstream
 #ifndef DISABLE_COLOR
 	if (strcasecmp(rcopts[i].name, "titlecolor") == 0)
 	    specified_color_combo[TITLE_BAR] = option;
+	else if (strcasecmp(rcopts[i].name, "numbercolor") == 0)
+	    specified_color_combo[LINE_NUMBER] = option;
 	else if (strcasecmp(rcopts[i].name, "statuscolor") == 0)
 	    specified_color_combo[STATUS_BAR] = option;
 	else if (strcasecmp(rcopts[i].name, "keycolor") == 0)
diff --git a/src/winio.c b/src/winio.c
index d2d6e16777f8f142c31d053384dddca05c2aac8a..4330814bf5111a8e8e11ebd788f0fb04859d44e2 100644
--- a/src/winio.c
+++ b/src/winio.c
@@ -2278,12 +2278,12 @@ void edit_draw(filestruct *fileptr, const char *converted, int
 	}
 
 	/* Show the line number only for the non-softwrapped parts. */
-	wattron(edit, hilite_attribute);
+	wattron(edit, interface_color_pair[LINE_NUMBER]);
 	if (last_drawn_line != fileptr->lineno || last_line_y >= line)
 	    mvwprintw(edit, line, 0, "%*i", margin - 1, fileptr->lineno);
 	else
 	    mvwprintw(edit, line, 0, "%*s", margin - 1, " ");
-	wattroff(edit, hilite_attribute);
+	wattroff(edit, interface_color_pair[LINE_NUMBER]);
     } else {
 	margin = 0;
 	editwincols = COLS;