His resignation in 1717 from a position where he must have been so happy comes as a surprise. In November of that year he moved with his family to the court of Prince Leopold of Anhalt-Cöthen, where he had been appointed chapel master and director of the prince’s chamber music. Anhalt-Cöthen was a flourishing little community. The prince, himself hardly more than a youth, was generous and free in spirit, fond of art and of music. He played the violin, the 'cello, and the harpsichord, and seems to have been an excellent bass singer as well. His interest was chiefly in secular instrumental music. There was no good organ at the court nor any trained choir of singers, but there was probably a good band, though the names of only a few players have been preserved. Among them is Christopher Ferdinand Abel, whose son, Carl Friedrich, shared with Sebastian Bach’s son Christian the high honors of the musical world of London in the next generation. Through them the young Mozart was destined to be influenced. It is indeed curious to find the fathers of the two men playing in the same little court band. Just what Bach’s duties were in his new position has never been discovered. It was a good appointment and well paid, and he was in high favor with the young prince. But, as Spitta has eloquently written, time has effaced or overgrown almost every trace of his labors, as the grass has overgrown the castle yard which he must so often have crossed, and his name has died out among the people of the place almost as completely as the sounds with which he once roused the echoes of the now empty and deserted halls.

The six years spent at Cöthen were the happiest of his life. It will seem strange to those who think of Bach as a composer of religious music and organ music that he could have treasured in his memory these years at Cöthen, when his energy was directed almost wholly to the composition of chamber music. Yet such was the case. The explanation of this seeming riddle is to be found in his personal character and in the peculiar quality of his genius. For all the independent strength of his will and his intellect, his was essentially a meditative nature, which found its truest expression apart from the public, and in the small intimate forms of chamber music. He delighted in the circle of his family, he delighted in the tender, faint music of the clavichord, which, we are assured, was his favorite instrument. The glory and majesty of his great power are in his music for the organ, the exaltation of his spirit is in the St. Matthew Passion and in the mass in B minor, but nowhere is the essence of his heart so warm, so simple and so unadorned as in the music he composed for clavichord, for violin, and for 'cello while he was at Cöthen.

His life went quietly on there within the court, broken by occasional journeys such as he was accustomed to take from Weimar. In the autumn of 1719 he passed through Halle, where Handel was staying for a short while with his family, during the trip he made from London to Italy, in search of singers. Bach made an effort to meet him, only to find that Handel had just departed. Later in life he again attempted to see and talk with the world-famous master, and again failed. The two greatest musicians of their time never met.

On the seventh of July, 1720, while Bach was away with his prince, his wife died. Left with four young children, he married again, in about a year and a half, Anna Magdalena Wülker, youngest daughter of Johann Caspar Wülker, court trumpeter at Weissenfels. She was at that time twenty-one years old, intensely musical and was an excellent singer. She was, moreover, skillful with the pen, and helped her husband in copying his own and other music. Her clear, flowing handwriting can be seen in the manuscript copies of the solo violin and violoncello sonatas, and in those of later works. That she worked diligently to master the clavichord is only one of the many instances of her desire to improve her knowledge of music in every way that would help her to follow and assist her husband. She thus became the centre of a home life which must have been in many ways the source of cheer and deep happiness to her husband and her family. How much this meant to Bach as he grew older amid the vexations of his post in the St. Thomas school in Leipzig cannot be overestimated, for, as we have already said, he was at heart a man who withdrew from the bustle of society and the world at large into the intimacy of home life.

The list of works he composed at Cöthen is a long one and momentous in the history of music. Many of them are epoch-making; all bear the marks of his undying genius in their workmanship, in their perfection of form and of detail, in the warmth of the inspiration that prompted them. Inasmuch as during the six years of his stay there he devoted himself almost solely to the composition of secular instrumental music, the period stands out distinct and unique in his life. What his daily life was, what his actual duties at the court, we do not know; but that they were happy years the music he wrote attests. Moreover, we have his own word written some years later to a friend in Russia that he would have been content to pass the remainder of his days there. But the marriage of Prince Leopold in 1722 seems to have changed the spirit of the court. The young princess had no special fondness for music, and Bach no longer felt himself in congenial surroundings. In 1722 the venerable Johann Kuhnau, cantor of the St. Thomas school in Leipzig, died. Within a year Bach obtained the post, moved with his family to Leipzig, and at the end of May, 1723, was installed in the position which he was to hold until the time of his death.

The St. Thomas school was an adjunct of the old St. Thomas church. It had been founded in the thirteenth century, and up to the time of the Reformation had been under the control of Augustinian monks, but at that time had been taken into the control of the municipal council. Bach was, therefore, in the employ of the town authorities, for the most part men with little knowledge or love of music, with whom he was seldom in good accord. From the earliest times the main purpose of the school had been to train singers for the church of St. Thomas and later for the church of St. Nicholas, but it was a charity school for orphans as well, and most of the boys were unruly. Bach’s chief duties were the training of these choir boys and the furnishing of music for the St. Thomas and St. Nicholas churches. Officially he had nothing to do with the organ in either church.[156]

Bach was beset by difficulties and unpleasantness on every hand. To begin, the school was disorganized and the boys unruly, as we have said. Nor was music in very high respect there, if we may judge by the prospectus of studies which said that, next to the glory of God, the chief aim of singing was to promote the pupils’ digestions. Bach’s work with them was not heavy. On Monday, Tuesday, and Wednesday he had to give a lesson in music at nine, and one at twelve, and on Friday one at twelve. On Friday, too, he had to take the boys to church at seven in the morning, and on Saturday at the same time had to expound the Latin catechism to the third and fourth classes. On certain days in the week he had to give a Latin lesson to the third class. On Thursday he was free. The rehearsals of the Sunday music took place regularly on Saturday afternoon. But the boys were frequently in bad condition. It was a custom for them to parade through the streets from time to time at various houses for donations. Their voices were often ruined by colds, and Bach could have had but little pleasure in training such material. Moreover, the spirit of the school had been demoralized by the light Italian music which had gained a foothold through the town opera house, and through Telemann, organist at the New Church, and the boys frequently deserted the school to sing in the musical union which Telemann had organized. However, in the course of a few years Bach got control of the musical union and of music in the famous old university as well, and was thus in a position to train a portion of the inhabitants of the town to an appreciation of his own kind of music.

From the start he set himself vigorously to reform and improve the condition of music in the St. Thomas and St. Nicholas churches. To this end he tried to get hold of as many singers and as many players as possible. Here he was in constant conflict with the town council, who refused to furnish him with money necessary to engage the boys and men he needed. In August, 1730, he submitted to the council a statement of what material should be rightly placed at his service if he was expected to furnish ‘well-appointed church music,’ and a brief and very telling account of what he actually had. Concerning the instrumentalists necessary to accompany church cantatas, etc., he writes: ‘In all, at least eighteen persons are needed for instruments. The number appointed is eight, four town pipers, three town violinists, and one assistant. Discretion forbids me telling the plain truth as to their ability and musical knowledge; however, it ought to be considered that they are partly inefficient and partly not in such good practice as they should be. The most important instruments for supporting the parts, and the most indispensable in themselves are wanting.’ He gives the names of the boys in the school, dividing them into three classes: ‘seventeen available, twenty not yet available, and seventeen useless.’ The statement was quite ignored by the town council. Up to the year 1746 no additional appropriation was devoted to keeping up the music in the churches of St. Thomas and St. Nicholas. That Bach was angry and embittered by such a disregard is evident in the famous letter to his friend Erdmann, in which he wrote, among other things, that the appointment was by no means so advantageous as it had been described to him, that many fees incidental to it had been stopped, that the town was very dear to live in and the authorities were very strange folks with no love of music, so that he lived under almost constant vexation, jealousy, and persecution; finally, that he felt compelled to seek his fortune, with God’s assistance, elsewhere.[157]

Affairs could not have been quite so hopeless as Bach felt they were. At any rate, he seems to have done nothing more in the way of finding another position. It can hardly be doubted that he would have had no difficulty in doing so had he long wanted to. His fame as an organist was widespread over Germany; and he was a man of firmest determination and no end of courage. He must have decided that the advantages Leipzig offered him outweighed the disadvantages under which the stupidity or indifference of the town council placed him. Moreover, shortly after this affair, in fact, just before the letter to Erdmann was written, a new rector, J. M. Gesner, was appointed to the St. Thomas school, a man who never failed in his appreciation of Bach and sympathy with his aims, and who, most important of all, had the special talent of managing boys, and was able in the few years of his stay in Leipzig to establish order and to put the school upon a new and solid foundation. He probably succeeded in easing the relations between Bach and the town council, and through his efforts Bach was released from giving lessons in Latin and all other general instruction apart from music.